diff options
author | Lunny Xiao <xiaolunwen@gmail.com> | 2025-01-09 11:51:03 -0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2025-01-10 03:51:03 +0800 |
commit | 39d51e7c82d6c37956c32844b3031b9a00cfbc77 (patch) | |
tree | 846d54606329c58c53cf273c179a32402962a5ef /models/migrations/migrations.go | |
parent | 2298ff2152e5f678b4567af950527d59d17c7e68 (diff) | |
download | gitea-39d51e7c82d6c37956c32844b3031b9a00cfbc77.tar.gz gitea-39d51e7c82d6c37956c32844b3031b9a00cfbc77.zip |
Automerge supports deleting branch automatically after merging (#32343)
Resolve #32341
~Depends on #27151~
- [x] It will display a checkbox of deleting the head branch on the pull
request view page when starting an auto-merge task.
- [x] Add permission check before deleting the branch
- [x] Add delete branch comment for those closing pull requests because
of head branch or base branch was deleted.
- [x] Merge `RetargetChildrenOnMerge` and `AddDeletePRBranchComment`
into `service.DeleteBranch`.
Diffstat (limited to 'models/migrations/migrations.go')
-rw-r--r-- | models/migrations/migrations.go | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/models/migrations/migrations.go b/models/migrations/migrations.go index 52d10c4fe8..95364ab705 100644 --- a/models/migrations/migrations.go +++ b/models/migrations/migrations.go @@ -22,6 +22,7 @@ import ( "code.gitea.io/gitea/models/migrations/v1_21" "code.gitea.io/gitea/models/migrations/v1_22" "code.gitea.io/gitea/models/migrations/v1_23" + "code.gitea.io/gitea/models/migrations/v1_24" "code.gitea.io/gitea/models/migrations/v1_6" "code.gitea.io/gitea/models/migrations/v1_7" "code.gitea.io/gitea/models/migrations/v1_8" @@ -369,6 +370,9 @@ func prepareMigrationTasks() []*migration { newMigration(309, "Improve Notification table indices", v1_23.ImproveNotificationTableIndices), newMigration(310, "Add Priority to ProtectedBranch", v1_23.AddPriorityToProtectedBranch), newMigration(311, "Add TimeEstimate to Issue table", v1_23.AddTimeEstimateColumnToIssueTable), + + // Gitea 1.23.0-rc0 ends at migration ID number 311 (database version 312) + newMigration(312, "Add DeleteBranchAfterMerge to AutoMerge", v1_24.AddDeleteBranchAfterMergeForAutoMerge), } return preparedMigrations } |