migrate

package
v0.0.0-...-4c964c4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 29, 2025 License: Apache-2.0 Imports: 26 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

WireSet provides a wire set for this package.

Functions

This section is empty.

Types

type Controller

type Controller struct {
	// contains filtered or unexported fields
}

func NewController

func NewController(
	authorizer authz.Authorizer,
	publicAccess publicaccess.Service,
	git git.Interface,
	urlProvider url.Provider,
	pullreqImporter *migrate.PullReq,
	ruleImporter *migrate.Rule,
	webhookImporter *migrate.Webhook,
	labelImporter *migrate.Label,
	resourceLimiter limiter.ResourceLimiter,
	auditService audit.Service,
	identifierCheck check.RepoIdentifier,
	tx dbtx.Transactor,
	spaceStore store.SpaceStore,
	repoStore store.RepoStore,
) *Controller

func ProvideController

func ProvideController(
	authorizer authz.Authorizer,
	publicAccess publicaccess.Service,
	rpcClient git.Interface,
	urlProvider url.Provider,
	pullreqImporter *migrate.PullReq,
	ruleImporter *migrate.Rule,
	webhookImporter *migrate.Webhook,
	labelImporter *migrate.Label,
	resourceLimiter limiter.ResourceLimiter,
	auditService audit.Service,
	identifierCheck check.RepoIdentifier,
	tx dbtx.Transactor,
	spaceStore store.SpaceStore,
	repoStore store.RepoStore,
) *Controller

func (*Controller) CreateRepo

func (c *Controller) CreateRepo(
	ctx context.Context,
	session *auth.Session,
	in *CreateRepoInput,
) (*repoCtrl.RepositoryOutput, error)

func (*Controller) Labels

func (c *Controller) Labels(
	ctx context.Context,
	session *auth.Session,
	parentRef string,
	in *LabelsInput,
) ([]*types.Label, error)

func (*Controller) PullRequests

func (c *Controller) PullRequests(
	ctx context.Context,
	session *auth.Session,
	repoRef string,
	in *PullreqsInput,
) ([]*types.PullReq, error)

func (*Controller) Rules

func (c *Controller) Rules(
	ctx context.Context,
	session *auth.Session,
	repoRef string,
	in *RulesInput,
) ([]*types.Rule, error)

func (*Controller) UpdateRepoState

func (c *Controller) UpdateRepoState(
	ctx context.Context,
	session *auth.Session,
	repoRef string,
	in *UpdateStateInput,
) (*types.Repository, error)

func (*Controller) Webhooks

func (c *Controller) Webhooks(
	ctx context.Context,
	session *auth.Session,
	repoRef string,
	in *WebhooksInput,
) ([]*types.Webhook, error)

type CreateRepoInput

type CreateRepoInput struct {
	ParentRef     string `json:"parent_ref"`
	Identifier    string `json:"identifier"`
	DefaultBranch string `json:"default_branch"`
	IsPublic      bool   `json:"is_public"`
}

type LabelsInput

type LabelsInput struct {
	Labels []*migrate.ExternalLabel `json:"labels"`
}

type PullreqsInput

type PullreqsInput struct {
	PullRequestData []*migrate.ExternalPullRequest `json:"pull_request_data"`
}

type RulesInput

type RulesInput struct {
	Rules []*migrate.ExternalRule  `json:"rules"`
	Type  migrate.ExternalRuleType `json:"type"`
}

type UpdateStateInput

type UpdateStateInput struct {
	State enum.RepoState `json:"state"`
}

type WebhooksInput

type WebhooksInput struct {
	Webhooks []*migrate.ExternalWebhook `json:"hooks"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL