From 0989c4c36b34490880bf901015eb542f97a6a62a Mon Sep 17 00:00:00 2001 From: floss4good Date: Sun, 16 Feb 2025 08:17:33 +0000 Subject: [PATCH] fix: forgejo migrations numbering in comments and rename latest migration file (#6957) fixes #6955 ## Checklist The [contributor guide](https://forgejo.org/docs/next/contributor/) contains information that will be helpful to first time contributors. There also are a few [conditions for merging Pull Requests in Forgejo repositories](https://codeberg.org/forgejo/governance/src/branch/main/PullRequestsAgreement.md). You are also welcome to join the [Forgejo development chatroom](https://matrix.to/#/#forgejo-development:matrix.org). ### Tests - I added test coverage for Go changes... - [ ] in their respective `*_test.go` for unit tests. - [ ] in the `tests/integration` directory if it involves interactions with a live Forgejo server. - I added test coverage for JavaScript changes... - [ ] in `web_src/js/*.test.js` if it can be unit tested. - [ ] in `tests/e2e/*.test.e2e.js` if it requires interactions with a live Forgejo server (see also the [developer guide for JavaScript testing](https://codeberg.org/forgejo/forgejo/src/branch/forgejo/tests/e2e/README.md#end-to-end-tests)). ### Documentation - [ ] I created a pull request [to the documentation](https://codeberg.org/forgejo/docs) to explain to Forgejo users how to use this change. - [x] I did not document these changes and I do not expect someone else to do it. ### Release notes - [x] I do not want this change to show in the release notes. - [ ] I want the title to show in the release notes with a link to this pull request. - [ ] I want the content of the `release-notes/.md` to be be used for the release notes instead of the title. Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/6957 Reviewed-by: Earl Warren Co-authored-by: floss4good Co-committed-by: floss4good --- models/forgejo_migrations/migrate.go | 36 ++++++++++---------- models/forgejo_migrations/{v29.go => v28.go} | 0 2 files changed, 18 insertions(+), 18 deletions(-) rename models/forgejo_migrations/{v29.go => v28.go} (100%) diff --git a/models/forgejo_migrations/migrate.go b/models/forgejo_migrations/migrate.go index 4bc17a4288..935b072331 100644 --- a/models/forgejo_migrations/migrate.go +++ b/models/forgejo_migrations/migrate.go @@ -58,41 +58,41 @@ var migrations = []*Migration{ NewMigration("Add the `apply_to_admins` column to the `protected_branch` table", forgejo_v1_22.AddApplyToAdminsSetting), // v9 -> v10 NewMigration("Add pronouns to user", forgejo_v1_22.AddPronounsToUser), - // v11 -> v12 + // v10 -> v11 NewMigration("Add the `created` column to the `issue` table", forgejo_v1_22.AddCreatedToIssue), - // v12 -> v13 + // v11 -> v12 NewMigration("Add repo_archive_download_count table", forgejo_v1_22.AddRepoArchiveDownloadCount), - // v13 -> v14 + // v12 -> v13 NewMigration("Add `hide_archive_links` column to `release` table", AddHideArchiveLinksToRelease), - // v14 -> v15 + // v13 -> v14 NewMigration("Remove Gitea-specific columns from the repository and badge tables", RemoveGiteaSpecificColumnsFromRepositoryAndBadge), - // v15 -> v16 + // v14 -> v15 NewMigration("Create the `federation_host` table", CreateFederationHostTable), - // v16 -> v17 + // v15 -> v16 NewMigration("Create the `federated_user` table", CreateFederatedUserTable), - // v17 -> v18 + // v16 -> v17 NewMigration("Add `normalized_federated_uri` column to `user` table", AddNormalizedFederatedURIToUser), - // v18 -> v19 + // v17 -> v18 NewMigration("Create the `following_repo` table", CreateFollowingRepoTable), - // v19 -> v20 + // v18 -> v19 NewMigration("Add external_url to attachment table", AddExternalURLColumnToAttachmentTable), - // v20 -> v21 + // v19 -> v20 NewMigration("Creating Quota-related tables", CreateQuotaTables), - // v21 -> v22 + // v20 -> v21 NewMigration("Add SSH keypair to `pull_mirror` table", AddSSHKeypairToPushMirror), - // v22 -> v23 + // v21 -> v22 NewMigration("Add `legacy` to `web_authn_credential` table", AddLegacyToWebAuthnCredential), - // v23 -> v24 + // v22 -> v23 NewMigration("Add `delete_branch_after_merge` to `auto_merge` table", AddDeleteBranchAfterMergeToAutoMerge), - // v24 -> v25 + // v23 -> v24 NewMigration("Add `purpose` column to `forgejo_auth_token` table", AddPurposeToForgejoAuthToken), - // v25 -> v26 + // v24 -> v25 NewMigration("Migrate `secret` column to store keying material", MigrateTwoFactorToKeying), - // v26 -> v27 + // v25 -> v26 NewMigration("Add `hash_blake2b` column to `package_blob` table", AddHashBlake2bToPackageBlob), - // v27 -> v28 + // v26 -> v27 NewMigration("Add `created_unix` column to `user_redirect` table", AddCreatedUnixToRedirect), - // v28 -> v29 + // v27 -> v28 NewMigration("Add pronoun privacy settings to user", AddHidePronounsOptionToUser), } diff --git a/models/forgejo_migrations/v29.go b/models/forgejo_migrations/v28.go similarity index 100% rename from models/forgejo_migrations/v29.go rename to models/forgejo_migrations/v28.go