]> source.dussan.org Git - gitea.git/commit
Validate migration files (#18203)
authorAravinth Manivannan <realaravinth@batsense.net>
Wed, 26 Jan 2022 09:45:51 +0000 (09:45 +0000)
committerGitHub <noreply@github.com>
Wed, 26 Jan 2022 09:45:51 +0000 (10:45 +0100)
commit3bb028cc46401a8a54ecab7e7c035dbb24937b6c
treebff1aaaaa9d5eef6b9d1c520337e3cc51153b9e2
parent49dd9067535538771ef13623ed1dd9698a4a2151
Validate migration files (#18203)

JSON Schema validation for data used by Gitea during migrations

Discussion at https://forum.forgefriends.org/t/common-json-schema-for-repository-information/563

Co-authored-by: Loïc Dachary <loic@dachary.org>
26 files changed:
.gitignore
cmd/restore_repo.go
go.mod
go.sum
integrations/dump_restore_test.go
modules/migration/file_format.go [new file with mode: 0644]
modules/migration/file_format_test.go [new file with mode: 0644]
modules/migration/file_format_testdata/issue_a.json [new file with mode: 0644]
modules/migration/file_format_testdata/issue_a.yml [new file with mode: 0644]
modules/migration/file_format_testdata/issue_b.json [new file with mode: 0644]
modules/migration/file_format_testdata/milestones.json [new file with mode: 0644]
modules/migration/issue.go
modules/migration/label.go
modules/migration/milestone.go
modules/migration/reaction.go
modules/migration/schemas/issue.json [new file with mode: 0644]
modules/migration/schemas/label.json [new file with mode: 0644]
modules/migration/schemas/milestone.json [new file with mode: 0644]
modules/migration/schemas/reaction.json [new file with mode: 0644]
modules/migration/schemas_bindata.go [new file with mode: 0644]
modules/migration/schemas_dynamic.go [new file with mode: 0644]
modules/migration/schemas_static.go [new file with mode: 0644]
modules/private/restore_repo.go
routers/private/restore_repo.go
services/migrations/dump.go
services/migrations/restore.go