Documentation ¶
Index ¶
- type BitbucketConnection
- type GitConnection
- type GithubConnection
- type GitlabConnection
- type Repository
- type RepositoryImpl
- func (vcr *RepositoryImpl) Create(connection *VcsConnection) (*VcsConnection, error)
- func (vcr *RepositoryImpl) Delete(organizationId uuid.UUID, connectionId uuid.UUID) error
- func (vcr *RepositoryImpl) Get(organizationId uuid.UUID, connectionId uuid.UUID) (*VcsConnection, error)
- func (vcr *RepositoryImpl) GetByWebhookId(webhookId uuid.UUID) (*VcsConnection, error)
- func (vcr *RepositoryImpl) List(organizationId uuid.UUID) ([]VcsConnection, error)
- type VcsConnection
- type Webhook
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BitbucketConnection ¶
type BitbucketConnection struct { }
type GitConnection ¶
type GitConnection struct { }
type GithubConnection ¶
type GitlabConnection ¶
type GitlabConnection struct { }
type Repository ¶ added in v1.2.1
type Repository interface { List(organizationId uuid.UUID) ([]VcsConnection, error) Get(organizationId uuid.UUID, connectionId uuid.UUID) (*VcsConnection, error) GetByWebhookId(webhookId uuid.UUID) (*VcsConnection, error) Create(connection *VcsConnection) (*VcsConnection, error) Delete(organizationId uuid.UUID, connectionId uuid.UUID) error }
func New ¶ added in v1.2.1
func New(db *gorm.DB) Repository
type RepositoryImpl ¶ added in v1.2.1
func (*RepositoryImpl) Create ¶ added in v1.2.1
func (vcr *RepositoryImpl) Create(connection *VcsConnection) (*VcsConnection, error)
func (*RepositoryImpl) Get ¶ added in v1.2.1
func (vcr *RepositoryImpl) Get(organizationId uuid.UUID, connectionId uuid.UUID) (*VcsConnection, error)
func (*RepositoryImpl) GetByWebhookId ¶ added in v1.7.0
func (vcr *RepositoryImpl) GetByWebhookId(webhookId uuid.UUID) (*VcsConnection, error)
func (*RepositoryImpl) List ¶ added in v1.2.1
func (vcr *RepositoryImpl) List(organizationId uuid.UUID) ([]VcsConnection, error)
type VcsConnection ¶
type VcsConnection struct { ID uuid.UUID `gorm:"type:uuid;default:gen_random_uuid()" json:"id"` CreatedAt time.Time `json:"created_at"` UpdatedAt time.Time `json:"updated_at"` DeletedAt *time.Time `sql:"index" json:"deleted_at"` Name string `json:"name"` // One of github, gitlab, bitbucket, or git Provider string `json:"provider"` Github GithubConnection `gorm:"embedded;embeddedPrefix:github_" json:"github,omitempty"` Gitlab GitlabConnection `gorm:"embedded;embeddedPrefix:gitlab_" json:"gitlab,omitempty"` Bitbucket BitbucketConnection `gorm:"embedded;embeddedPrefix:bitbucket_" json:"bitbucket,omitempty"` Git GitConnection `gorm:"embedded;embeddedPrefix:git_" json:"git,omitempty"` OrganizationID uuid.UUID `json:"organization_id"` Organization organization.Organization `json:"-"` Webhook Webhook `gorm:"embedded;embeddedPrefix:webhook_" json:"webhook,omitempty"` }
Click to show internal directories.
Click to hide internal directories.