repo

package
v1.21.4 Latest Latest
Warning

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

Go to latest
Published: Jan 17, 2024 License: MIT Imports: 107 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

View Source
var IssueTemplateCandidates = []string{
	"ISSUE_TEMPLATE.md",
	"ISSUE_TEMPLATE.yaml",
	"ISSUE_TEMPLATE.yml",
	"issue_template.md",
	"issue_template.yaml",
	"issue_template.yml",
	".gitea/ISSUE_TEMPLATE.md",
	".gitea/ISSUE_TEMPLATE.yaml",
	".gitea/ISSUE_TEMPLATE.yml",
	".gitea/issue_template.md",
	".gitea/issue_template.yaml",
	".gitea/issue_template.yml",
	".github/ISSUE_TEMPLATE.md",
	".github/ISSUE_TEMPLATE.yaml",
	".github/ISSUE_TEMPLATE.yml",
	".github/issue_template.md",
	".github/issue_template.yaml",
	".github/issue_template.yml",
}

IssueTemplateCandidates issue templates

Functions

func Action

func Action(ctx *context.Context)

Action response for actions to a repository

func Activity

func Activity(ctx *context.Context)

Activity render the page to show repository latest changes

func ActivityAuthors

func ActivityAuthors(ctx *context.Context)

ActivityAuthors renders JSON with top commit authors for given time period over all branches

func AddBoardToProjectPost

func AddBoardToProjectPost(ctx *context.Context)

AddBoardToProjectPost allows a new board to be added to a project.

func AddDependency

func AddDependency(ctx *context.Context)

AddDependency adds new dependencies

func AddTimeManually

func AddTimeManually(c *context.Context)

AddTimeManually tracks time manually

func BatchDeleteIssues added in v1.21.0

func BatchDeleteIssues(ctx *context.Context)

func Branches

func Branches(ctx *context.Context)

Branches render repository branch page

func CancelAutoMergePullRequest added in v1.17.0

func CancelAutoMergePullRequest(ctx *context.Context)

CancelAutoMergePullRequest cancels a scheduled pr

func CancelStopwatch

func CancelStopwatch(c *context.Context)

CancelStopwatch cancel the stopwatch

func ChangeCommentReaction

func ChangeCommentReaction(ctx *context.Context)

ChangeCommentReaction create a reaction for comment

func ChangeIssueReaction

func ChangeIssueReaction(ctx *context.Context)

ChangeIssueReaction create a reaction for issue

func ChangeMilestoneStatus

func ChangeMilestoneStatus(ctx *context.Context)

ChangeMilestoneStatus response for change a milestone's status

func ChangeProjectStatus

func ChangeProjectStatus(ctx *context.Context)

ChangeProjectStatus updates the status of a project between "open" and "close"

func CherryPick added in v1.17.0

func CherryPick(ctx *context.Context)

CherryPick handles cherrypick GETs

func CherryPickPost added in v1.17.0

func CherryPickPost(ctx *context.Context)

CherryPickPost handles cherrypick POSTs

func CleanUpPullRequest

func CleanUpPullRequest(ctx *context.Context)

CleanUpPullRequest responses for delete merged branch when PR has been merged

func CommitInfoCache added in v1.20.0

func CommitInfoCache(ctx *context.Context)

func Commits

func Commits(ctx *context.Context)

Commits render branch's commits

func CompareAndPullRequestPost

func CompareAndPullRequestPost(ctx *context.Context)

CompareAndPullRequestPost response for creating pull request

func CompareDiff

func CompareDiff(ctx *context.Context)

CompareDiff show different from one commit to another commit

func CorsHandler added in v1.20.0

func CorsHandler() func(next http.Handler) http.Handler

func Create

func Create(ctx *context.Context)

Create render creating repository page

func CreateBranch

func CreateBranch(ctx *context.Context)

CreateBranch creates new branch in repository

func CreateCodeComment

func CreateCodeComment(ctx *context.Context)

CreateCodeComment will create a code comment including an pending review if required

func CreatePost

func CreatePost(ctx *context.Context)

CreatePost response for creating repository

func DeleteAttachment

func DeleteAttachment(ctx *context.Context)

DeleteAttachment response for deleting issue's attachment

func DeleteBranchPost

func DeleteBranchPost(ctx *context.Context)

DeleteBranchPost responses for delete merged branch

func DeleteComment

func DeleteComment(ctx *context.Context)

DeleteComment delete comment of issue

func DeleteFile

func DeleteFile(ctx *context.Context)

DeleteFile render delete file page

func DeleteFilePost

func DeleteFilePost(ctx *context.Context)

DeleteFilePost response for deleting file

func DeleteIssue added in v1.17.0

func DeleteIssue(ctx *context.Context)

DeleteIssue deletes an issue

func DeleteLabel

func DeleteLabel(ctx *context.Context)

DeleteLabel delete a label

func DeleteMilestone

func DeleteMilestone(ctx *context.Context)

DeleteMilestone delete a milestone

func DeleteProject

func DeleteProject(ctx *context.Context)

DeleteProject delete a project

func DeleteProjectBoard

func DeleteProjectBoard(ctx *context.Context)

DeleteProjectBoard allows for the deletion of a project board

func DeleteRelease

func DeleteRelease(ctx *context.Context)

DeleteRelease deletes a release

func DeleteTag

func DeleteTag(ctx *context.Context)

DeleteTag deletes a tag

func DeleteTime

func DeleteTime(c *context.Context)

DeleteTime deletes tracked time

func DeleteWikiPagePost

func DeleteWikiPagePost(ctx *context.Context)

DeleteWikiPagePost delete wiki page

func Diff

func Diff(ctx *context.Context)

Diff show different from current commit to previous commit

func DiffPreviewPost

func DiffPreviewPost(ctx *context.Context)

DiffPreviewPost render preview diff page

func DismissReview

func DismissReview(ctx *context.Context)

DismissReview dismissing stale review by repo admin

func Download

func Download(ctx *context.Context)

Download an archive of a repository

func DownloadByID

func DownloadByID(ctx *context.Context)

DownloadByID download a file by sha1 ID

func DownloadByIDOrLFS

func DownloadByIDOrLFS(ctx *context.Context)

DownloadByIDOrLFS download a file by sha1 ID taking account of LFS

func DownloadPullDiff

func DownloadPullDiff(ctx *context.Context)

DownloadPullDiff render a pull's raw diff

func DownloadPullDiffOrPatch

func DownloadPullDiffOrPatch(ctx *context.Context, patch bool)

DownloadPullDiffOrPatch render a pull's raw diff or patch

func DownloadPullPatch

func DownloadPullPatch(ctx *context.Context)

DownloadPullPatch render a pull's raw patch

func EditFile

func EditFile(ctx *context.Context)

EditFile render edit file page

func EditFilePost

func EditFilePost(ctx *context.Context)

EditFilePost response for editing file

func EditMilestone

func EditMilestone(ctx *context.Context)

EditMilestone render edting milestone page

func EditMilestonePost

func EditMilestonePost(ctx *context.Context)

EditMilestonePost response for edting milestone

func EditProjectBoard

func EditProjectBoard(ctx *context.Context)

EditProjectBoard allows a project board's to be updated

func EditProjectPost

func EditProjectPost(ctx *context.Context)

EditProjectPost response for editing a project

func EditRelease

func EditRelease(ctx *context.Context)

EditRelease render release edit page

func EditReleasePost

func EditReleasePost(ctx *context.Context)

EditReleasePost response for edit release

func EditWiki

func EditWiki(ctx *context.Context)

EditWiki render wiki modify page

func EditWikiPost

func EditWikiPost(ctx *context.Context)

EditWikiPost response for wiki modify request

func ExcerptBlob

func ExcerptBlob(ctx *context.Context)

ExcerptBlob render blob excerpt contents

func FileHistory

func FileHistory(ctx *context.Context)

FileHistory show a file's reversions

func FindFiles added in v1.17.0

func FindFiles(ctx *context.Context)

FindFiles render the page to find repository files

func Fork

func Fork(ctx *context.Context)

Fork render repository fork page

func ForkPost

func ForkPost(ctx *context.Context)

ForkPost response for forking a repository

func Forks

func Forks(ctx *context.Context)

Forks render repository's forked users

func GetActionIssue

func GetActionIssue(ctx *context.Context) *issues_model.Issue

GetActionIssue will return the issue which is used in the context.

func GetActiveStopwatch

func GetActiveStopwatch(ctx *context.Context)

GetActiveStopwatch is the middleware that sets .ActiveStopwatch on context

func GetAttachment

func GetAttachment(ctx *context.Context)

GetAttachment serve attachments

func GetBranchesList added in v1.21.0

func GetBranchesList(ctx *context.Context)

GetBranchesList get branches for current repo'

func GetClosestParentWithFiles

func GetClosestParentWithFiles(treePath string, commit *git.Commit) string

GetClosestParentWithFiles Recursively gets the path of parent in a tree that has files (used when file in a tree is deleted). Returns "" for the root if no parents other than the root have files. If the given treePath isn't a SubTree or it has no entries, we go up one dir and see if we can return the user to that listing.

func GetCommentAttachments

func GetCommentAttachments(ctx *context.Context)

GetCommentAttachments returns attachments for the comment

func GetContentHistoryDetail added in v1.16.0

func GetContentHistoryDetail(ctx *context.Context)

GetContentHistoryDetail get detail

func GetContentHistoryList added in v1.16.0

func GetContentHistoryList(ctx *context.Context)

GetContentHistoryList get list

func GetContentHistoryOverview added in v1.16.0

func GetContentHistoryOverview(ctx *context.Context)

GetContentHistoryOverview get overview

func GetEditorConfig

func GetEditorConfig(ctx *context.Context, treePath string) string

GetEditorConfig returns a editorconfig JSON string for given treePath or "null"

func GetIdxFile

func GetIdxFile(ctx *context.Context)

GetIdxFile implements Git dumb HTTP

func GetInfoPacks

func GetInfoPacks(ctx *context.Context)

GetInfoPacks implements Git dumb HTTP

func GetInfoRefs

func GetInfoRefs(ctx *context.Context)

GetInfoRefs implements Git dumb HTTP

func GetIssueAttachments

func GetIssueAttachments(ctx *context.Context)

GetIssueAttachments returns attachments for the issue

func GetIssueInfo added in v1.17.0

func GetIssueInfo(ctx *context.Context)

GetIssueInfo get an issue of a repository

func GetLooseObject

func GetLooseObject(ctx *context.Context)

GetLooseObject implements Git dumb HTTP

func GetMergedBaseCommitID added in v1.21.0

func GetMergedBaseCommitID(ctx *context.Context, issue *issues_model.Issue) string

func GetPackFile

func GetPackFile(ctx *context.Context)

GetPackFile implements Git dumb HTTP

func GetPullCommits added in v1.21.0

func GetPullCommits(ctx *context.Context)

GetPullCommits get all commits for given pull request

func GetPullDiffStats added in v1.21.0

func GetPullDiffStats(ctx *context.Context)

GetPullDiffStats get Pull Requests diff stats

func GetTagList added in v1.21.0

func GetTagList(ctx *context.Context)

GetTagList get tag list for current repo

func GetTextFile

func GetTextFile(p string) func(*context.Context)

GetTextFile implements Git dumb HTTP

func GetUniquePatchBranchName

func GetUniquePatchBranchName(ctx *context.Context) string

GetUniquePatchBranchName Gets a unique branch name for a new patch branch It will be in the form of <username>-patch-<num> where <num> is the first branch of this format that doesn't already exist. If we exceed 1000 tries or an error is thrown, we just return "" so the user has to type in the branch name themselves (will be an empty field)

func Graph

func Graph(ctx *context.Context)

Graph render commit graph - show commits from all branches.

func HTTPGitEnabledHandler added in v1.20.0

func HTTPGitEnabledHandler(ctx *context.Context)

func HandleGitError added in v1.21.0

func HandleGitError(ctx *context.Context, msg string, err error)

func Home

func Home(ctx *context.Context)

Home render repository home page

func InitializeLabels

func InitializeLabels(ctx *context.Context)

InitializeLabels init labels for a repository

func InitiateDownload

func InitiateDownload(ctx *context.Context)

InitiateDownload will enqueue an archival request, as needed. It may submit a request that's already in-progress, but the archiver service will just kind of drop it on the floor if this is the case.

func IssuePinMove added in v1.20.0

func IssuePinMove(ctx *context.Context)

IssuePinMove moves a pinned Issue

func IssuePinOrUnpin added in v1.20.0

func IssuePinOrUnpin(ctx *context.Context)

IssuePinOrUnpin pin or unpin a Issue

func IssuePosters added in v1.20.0

func IssuePosters(ctx *context.Context)

IssuePosters get posters for current repo's issues/pull requests

func IssueStopwatch

func IssueStopwatch(c *context.Context)

IssueStopwatch creates or stops a stopwatch for the given issue.

func IssueUnpin added in v1.20.0

func IssueUnpin(ctx *context.Context)

IssueUnpin unpins a Issue

func IssueWatch

func IssueWatch(ctx *context.Context)

IssueWatch sets issue watching

func Issues

func Issues(ctx *context.Context)

Issues render issues page

func Labels

func Labels(ctx *context.Context)

Labels render issue's labels page

func LastCommit added in v1.16.0

func LastCommit(ctx *context.Context)

LastCommit returns lastCommit data for the provided branch/tag/commit and directory (in url) and filenames in body

func LatestRelease

func LatestRelease(ctx *context.Context)

LatestRelease redirects to the latest release

func ListIssues added in v1.17.0

func ListIssues(ctx *context.Context)

ListIssues list the issues of a repository

func LoadBranchesAndTags added in v1.21.0

func LoadBranchesAndTags(ctx *context.Context)

func LockIssue

func LockIssue(ctx *context.Context)

LockIssue locks an issue. This would limit commenting abilities to users with write access to the repo.

func MakeSelfOnTop added in v1.21.0

func MakeSelfOnTop(doer *user.User, users []*user.User) []*user.User

func MergePullRequest

func MergePullRequest(ctx *context.Context)

MergePullRequest response for merging pull request

func Migrate

func Migrate(ctx *context.Context)

Migrate render migration of repository page

func MigrateCancelPost added in v1.20.0

func MigrateCancelPost(ctx *context.Context)

func MigratePost

func MigratePost(ctx *context.Context)

MigratePost response for migrating from external git repository

func MigrateRetryPost added in v1.21.0

func MigrateRetryPost(ctx *context.Context)

func MilestoneIssuesAndPulls

func MilestoneIssuesAndPulls(ctx *context.Context)

MilestoneIssuesAndPulls lists all the issues and pull requests of the milestone

func Milestones

func Milestones(ctx *context.Context)

Milestones render milestones page

func MoveIssues added in v1.16.0

func MoveIssues(ctx *context.Context)

MoveIssues moves or keeps issues in a column and sorts them inside that column

func MustAllowPulls

func MustAllowPulls(ctx *context.Context)

MustAllowPulls check if repository enable pull requests and user have right to do that

func MustAllowUserComment

func MustAllowUserComment(ctx *context.Context)

MustAllowUserComment checks to make sure if an issue is locked. If locked and user has permissions to write to the repository, then the comment is allowed, else it is blocked

func MustBeAbleToUpload

func MustBeAbleToUpload(ctx *context.Context)

MustBeAbleToUpload check that repo can be uploaded to

func MustBeEditable

func MustBeEditable(ctx *context.Context)

MustBeEditable check that repo can be edited

func MustBeNotEmpty

func MustBeNotEmpty(ctx *context.Context)

MustBeNotEmpty render when a repo is a empty git dir

func MustEnableIssues

func MustEnableIssues(ctx *context.Context)

MustEnableIssues check if repository enable internal issues

func MustEnableProjects

func MustEnableProjects(ctx *context.Context)

MustEnableProjects check if projects are enabled in settings

func MustEnableWiki

func MustEnableWiki(ctx *context.Context)

MustEnableWiki check if wiki is enabled, if external then redirect

func NewComment

func NewComment(ctx *context.Context)

NewComment create a comment for issue

func NewDiffPatch added in v1.17.0

func NewDiffPatch(ctx *context.Context)

NewDiffPatch render create patch page

func NewDiffPatchPost added in v1.17.0

func NewDiffPatchPost(ctx *context.Context)

NewDiffPatchPost response for sending patch page

func NewFile

func NewFile(ctx *context.Context)

NewFile render create file page

func NewFilePost

func NewFilePost(ctx *context.Context)

NewFilePost response for creating file

func NewIssue

func NewIssue(ctx *context.Context)

NewIssue render creating issue page

func NewIssueChooseTemplate

func NewIssueChooseTemplate(ctx *context.Context)

NewIssueChooseTemplate render creating issue from template page

func NewIssuePost

func NewIssuePost(ctx *context.Context)

NewIssuePost response for creating new issue

func NewLabel

func NewLabel(ctx *context.Context)

NewLabel create new label for repository

func NewMilestone

func NewMilestone(ctx *context.Context)

NewMilestone render creating milestone page

func NewMilestonePost

func NewMilestonePost(ctx *context.Context)

NewMilestonePost response for creating milestone

func NewProjectPost

func NewProjectPost(ctx *context.Context)

NewProjectPost creates a new project

func NewRelease

func NewRelease(ctx *context.Context)

NewRelease render creating or edit release page

func NewReleasePost

func NewReleasePost(ctx *context.Context)

NewReleasePost response for creating a release

func NewWiki

func NewWiki(ctx *context.Context)

NewWiki render wiki create page

func NewWikiPost

func NewWikiPost(ctx *context.Context)

NewWikiPost response for wiki create request

func Packages added in v1.17.0

func Packages(ctx *context.Context)

Packages displays a list of all packages in the repository

func PrepareBranchList added in v1.21.0

func PrepareBranchList(ctx *context.Context)

func PrepareCompareDiff

func PrepareCompareDiff(
	ctx *context.Context,
	ci *CompareInfo,
	whitespaceBehavior git.TrustedCmdArgs,
) bool

PrepareCompareDiff renders compare diff page

func PrepareMergedViewPullInfo

func PrepareMergedViewPullInfo(ctx *context.Context, issue *issues_model.Issue) *git.CompareInfo

PrepareMergedViewPullInfo show meta information for a merged pull request view page

func PrepareViewPullInfo

func PrepareViewPullInfo(ctx *context.Context, issue *issues_model.Issue) *git.CompareInfo

PrepareViewPullInfo show meta information for a pull request preview page

func Projects

func Projects(ctx *context.Context)

Projects renders the home page of projects

func PullPosters added in v1.20.1

func PullPosters(ctx *context.Context)

func RawCommitURL added in v1.16.0

func RawCommitURL(owner, name string, commit *git.Commit) string

RawCommitURL creates a relative URL for the raw commit in the given repository

func RawDiff

func RawDiff(ctx *context.Context)

RawDiff dumps diff results of repository in given commit ID to io.Writer

func RedirectDownload

func RedirectDownload(ctx *context.Context)

RedirectDownload return a file based on the following infos:

func RefBlame

func RefBlame(ctx *context.Context)

RefBlame render blame page

func RefCommits

func RefCommits(ctx *context.Context)

RefCommits render commits page

func Releases

func Releases(ctx *context.Context)

Releases render releases list page

func ReleasesFeedAtom added in v1.17.4

func ReleasesFeedAtom(ctx *context.Context)

ReleasesFeedAtom get feeds for releases in Atom format

func ReleasesFeedRSS added in v1.17.4

func ReleasesFeedRSS(ctx *context.Context)

ReleasesFeedRSS get feeds for releases in RSS format

func RemoveDependency

func RemoveDependency(ctx *context.Context)

RemoveDependency removes the dependency

func RemoveUploadFileFromServer

func RemoveUploadFileFromServer(ctx *context.Context)

RemoveUploadFileFromServer remove file from server file dir

func RenderEditProject added in v1.20.0

func RenderEditProject(ctx *context.Context)

RenderEditProject allows a project to be edited

func RenderFile added in v1.17.0

func RenderFile(ctx *context.Context)

RenderFile renders a file by repos path

func RenderNewCodeCommentForm

func RenderNewCodeCommentForm(ctx *context.Context)

RenderNewCodeCommentForm will render the form for creating a new review comment

func RenderNewProject added in v1.20.0

func RenderNewProject(ctx *context.Context)

RenderNewProject render creating a project page

func RenderUserCards

func RenderUserCards(ctx *context.Context, total int, getter func(opts db.ListOptions) ([]*user_model.User, error), tpl base.TplName)

RenderUserCards render a page show users according the input template

func RestoreBranchPost

func RestoreBranchPost(ctx *context.Context)

RestoreBranchPost responses for delete merged branch

func RetrieveLabels

func RetrieveLabels(ctx *context.Context)

RetrieveLabels find all the labels of a repository and organization

func RetrieveRepoMetas

func RetrieveRepoMetas(ctx *context.Context, repo *repo_model.Repository, isPull bool) []*issues_model.Label

RetrieveRepoMetas find all the meta information of a repository

func RetrieveRepoMilestonesAndAssignees

func RetrieveRepoMilestonesAndAssignees(ctx *context.Context, repo *repo_model.Repository)

RetrieveRepoMilestonesAndAssignees find all the milestones and assignees of a repository

func RetrieveRepoReviewers

func RetrieveRepoReviewers(ctx *context.Context, repo *repo_model.Repository, issue *issues_model.Issue, canChooseReviewer bool)

RetrieveRepoReviewers find all reviewers of a repository

func Search(ctx *context.Context)

Search render repository search page

func SearchCommits

func SearchCommits(ctx *context.Context)

SearchCommits render commits filtered by keyword

func SearchIssues added in v1.17.0

func SearchIssues(ctx *context.Context)

SearchIssues searches for issues across the repositories that the user has access to

func SearchRepo added in v1.17.0

func SearchRepo(ctx *context.Context)

SearchRepo repositories via options

func ServeAttachment added in v1.20.0

func ServeAttachment(ctx *context.Context, uuid string)

GetAttachment serve attachments with the given UUID

func ServeBlobOrLFS

func ServeBlobOrLFS(ctx *context.Context, blob *git.Blob, lastModified *time.Time) error

ServeBlobOrLFS download a git.Blob redirecting to LFS if necessary

func ServiceReceivePack

func ServiceReceivePack(ctx *context.Context)

ServiceReceivePack implements Git Smart HTTP protocol

func ServiceUploadPack

func ServiceUploadPack(ctx *context.Context)

ServiceUploadPack implements Git Smart HTTP protocol

func SetAllowEdits added in v1.17.0

func SetAllowEdits(ctx *context.Context)

SetAllowEdits allow edits from maintainers to PRs

func SetDefaultProjectBoard

func SetDefaultProjectBoard(ctx *context.Context)

SetDefaultProjectBoard set default board for uncategorized issues/pulls

func SetDiffViewStyle

func SetDiffViewStyle(ctx *context.Context)

SetDiffViewStyle set diff style as render variable

func SetEditorconfigIfExists

func SetEditorconfigIfExists(ctx *context.Context)

SetEditorconfigIfExists set editor config as render variable

func SetShowOutdatedComments added in v1.20.0

func SetShowOutdatedComments(ctx *context.Context)

SetShowOutdatedComments set the show outdated comments option as context variable

func SetWhitespaceBehavior

func SetWhitespaceBehavior(ctx *context.Context)

SetWhitespaceBehavior set whitespace behavior as render variable

func SingleDownload

func SingleDownload(ctx *context.Context)

SingleDownload download a file by repos path

func SingleDownloadOrLFS

func SingleDownloadOrLFS(ctx *context.Context)

SingleDownloadOrLFS download a file by repos path redirecting to LFS if necessary

func SingleRelease

func SingleRelease(ctx *context.Context)

SingleRelease renders a single release's page

func SoftDeleteContentHistory added in v1.16.0

func SoftDeleteContentHistory(ctx *context.Context)

SoftDeleteContentHistory soft delete

func SourceCommitURL added in v1.16.0

func SourceCommitURL(owner, name string, commit *git.Commit) string

SourceCommitURL creates a relative URL for a commit in the given repository

func Stars

func Stars(ctx *context.Context)

Stars render repository's starred users

func SubmitReview

func SubmitReview(ctx *context.Context)

SubmitReview creates a review out of the existing pending review or creates a new one if no pending review exist

func TagsList

func TagsList(ctx *context.Context)

TagsList render tags list page

func TagsListFeedAtom added in v1.17.4

func TagsListFeedAtom(ctx *context.Context)

TagsListFeedAtom get feeds for tags in RSS format

func TagsListFeedRSS added in v1.17.4

func TagsListFeedRSS(ctx *context.Context)

TagsListFeedRSS get feeds for tags in RSS format

func TopicsPost

func TopicsPost(ctx *context.Context)

TopicsPost response for creating repository

func TreeList added in v1.17.0

func TreeList(ctx *context.Context)

TreeList get all files' entries of a repository

func UnSetDefaultProjectBoard added in v1.20.0

func UnSetDefaultProjectBoard(ctx *context.Context)

UnSetDefaultProjectBoard unset default board for uncategorized issues/pulls

func UnlockIssue

func UnlockIssue(ctx *context.Context)

UnlockIssue unlocks a previously locked issue.

func UpdateCommentContent

func UpdateCommentContent(ctx *context.Context)

UpdateCommentContent change comment of issue's content

func UpdateIssueAssignee

func UpdateIssueAssignee(ctx *context.Context)

UpdateIssueAssignee change issue's or pull's assignee

func UpdateIssueContent

func UpdateIssueContent(ctx *context.Context)

UpdateIssueContent change issue's content

func UpdateIssueDeadline added in v1.17.0

func UpdateIssueDeadline(ctx *context.Context)

UpdateIssueDeadline updates an issue deadline

func UpdateIssueLabel

func UpdateIssueLabel(ctx *context.Context)

UpdateIssueLabel change issue's labels

func UpdateIssueMilestone

func UpdateIssueMilestone(ctx *context.Context)

UpdateIssueMilestone change issue's milestone

func UpdateIssueProject

func UpdateIssueProject(ctx *context.Context)

UpdateIssueProject change an issue's project

func UpdateIssueRef

func UpdateIssueRef(ctx *context.Context)

UpdateIssueRef change issue's ref (branch)

func UpdateIssueStatus

func UpdateIssueStatus(ctx *context.Context)

UpdateIssueStatus change issue's status

func UpdateIssueTitle

func UpdateIssueTitle(ctx *context.Context)

UpdateIssueTitle change issue's title

func UpdateLabel

func UpdateLabel(ctx *context.Context)

UpdateLabel update a label's name and color

func UpdatePullRequest

func UpdatePullRequest(ctx *context.Context)

UpdatePullRequest merge PR's baseBranch into headBranch

func UpdatePullRequestTarget

func UpdatePullRequestTarget(ctx *context.Context)

UpdatePullRequestTarget change pull request's target branch

func UpdatePullReviewRequest

func UpdatePullReviewRequest(ctx *context.Context)

UpdatePullReviewRequest add or remove review request

func UpdateResolveConversation

func UpdateResolveConversation(ctx *context.Context)

UpdateResolveConversation add or remove an Conversation resolved mark

func UpdateViewedFiles added in v1.17.0

func UpdateViewedFiles(ctx *context.Context)

func UploadFile

func UploadFile(ctx *context.Context)

UploadFile render upload file page

func UploadFilePost

func UploadFilePost(ctx *context.Context)

UploadFilePost response for uploading file

func UploadFileToServer

func UploadFileToServer(ctx *context.Context)

UploadFileToServer upload file to server file dir not git

func UploadIssueAttachment

func UploadIssueAttachment(ctx *context.Context)

UploadIssueAttachment response for Issue/PR attachments

func UploadReleaseAttachment

func UploadReleaseAttachment(ctx *context.Context)

UploadReleaseAttachment response for uploading release attachments

func ValidateRepoMetas

func ValidateRepoMetas(ctx *context.Context, form forms.CreateIssueForm, isPull bool) ([]int64, []int64, int64, int64)

ValidateRepoMetas check and returns repository's meta information

func ViewIssue

func ViewIssue(ctx *context.Context)

ViewIssue render issue view page

func ViewProject

func ViewProject(ctx *context.Context)

ViewProject renders the project board for a project

func ViewPullCommits

func ViewPullCommits(ctx *context.Context)

ViewPullCommits show commits for a pull request

func ViewPullFilesForAllCommitsOfPr added in v1.21.0

func ViewPullFilesForAllCommitsOfPr(ctx *context.Context)

func ViewPullFilesForRange added in v1.21.0

func ViewPullFilesForRange(ctx *context.Context)

func ViewPullFilesForSingleCommit added in v1.21.0

func ViewPullFilesForSingleCommit(ctx *context.Context)

func ViewPullFilesStartingFromCommit added in v1.21.0

func ViewPullFilesStartingFromCommit(ctx *context.Context)

func Watchers

func Watchers(ctx *context.Context)

Watchers render repository's watch users

func Wiki

func Wiki(ctx *context.Context)

Wiki renders single wiki page

func WikiPages

func WikiPages(ctx *context.Context)

WikiPages render wiki pages list page

func WikiPost added in v1.16.0

func WikiPost(ctx *context.Context)

WikiPost renders post of wiki page

func WikiRaw

func WikiRaw(ctx *context.Context)

WikiRaw outputs raw blob requested by user (image for example)

func WikiRevision

func WikiRevision(ctx *context.Context)

WikiRevision renders file revision list of wiki page

Types

type CompareInfo added in v1.16.0

type CompareInfo struct {
	HeadUser         *user_model.User
	HeadRepo         *repo_model.Repository
	HeadGitRepo      *git.Repository
	CompareInfo      *git.CompareInfo
	BaseBranch       string
	HeadBranch       string
	DirectComparison bool
}

CompareInfo represents the collected results from ParseCompareInfo

func ParseCompareInfo

func ParseCompareInfo(ctx *context.Context) *CompareInfo

ParseCompareInfo parse compare info between two commit for preparing comparing references

type PageMeta

type PageMeta struct {
	Name         string
	SubURL       string
	GitEntryName string
	UpdatedUnix  timeutil.TimeStamp
}

PageMeta wiki page meta information

type StopwatchTmplInfo

type StopwatchTmplInfo struct {
	IssueLink  string
	RepoSlug   string
	IssueIndex int64
	Seconds    int64
}

StopwatchTmplInfo is a view on a stopwatch specifically for template rendering

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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