Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

gitea dump: include version & Check InstallLock #12760

Merged
merged 4 commits into from
Sep 7, 2020

Conversation

6543
Copy link
Member

@6543 6543 commented Sep 7, 2020

close #12757

this way if it is restored and use with an later version it should migrate as usual

close #12759:

[user@PC gitea]$ ./gitea dump -c wrong-conf.ini -f gitea-dump.zip
2020/09/07 19:55:47 ...s/setting/setting.go:522:SetCustomPathAndConf() [W] Using 'custom' directory as relative origin for configuration file: '/home/maddl/git/own/gitea/custom/wrong-conf.ini'
2020/09/07 19:55:47 ...s/setting/setting.go:540:NewContext() [W] Custom config '/home/user/gitea/custom/wrong-conf.ini' not found, ignore this if you're running first time
2020/09/07 19:55:47 ...dules/setting/git.go:91:newGit() [I] Git Version: 2.28.0, Wire Protocol Version 2 Enabled
2020/09/07 19:55:47 cmd/dump.go:190:runDump() [E] Is '/home/user/gitea/custom/wrong-conf.ini' really the right config path?
2020/09/07 19:55:47 main.go:112:main() [F] Failed to run app with [./gitea dump -c wrong-conf.ini -f gitea-dump.zip]: gitea is not initialized

before it just tell the user: Failed to connect to database: Unknown database type:

@6543 6543 added the type/enhancement An improvement of existing functionality label Sep 7, 2020
@GiteaBot GiteaBot added the lgtm/need 1 This PR needs approval from one additional maintainer to be merged. label Sep 7, 2020
@6543 6543 added this to the 1.13.0 milestone Sep 7, 2020
@6543 6543 requested a review from zeripath September 7, 2020 17:53
@6543 6543 changed the title gitea dump: include version gitea dump: include version & Check InstallLock Sep 7, 2020
@GiteaBot GiteaBot added lgtm/done This PR has enough approvals to get merged. There are no important open reservations anymore. and removed lgtm/need 1 This PR needs approval from one additional maintainer to be merged. labels Sep 7, 2020
@codecov-commenter
Copy link

Codecov Report

Merging #12760 into master will decrease coverage by 0.00%.
The diff coverage is 38.98%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master   #12760      +/-   ##
==========================================
- Coverage   43.30%   43.29%   -0.01%     
==========================================
  Files         648      647       -1     
  Lines       71765    71799      +34     
==========================================
+ Hits        31077    31085       +8     
- Misses      35657    35677      +20     
- Partials     5031     5037       +6     
Impacted Files Coverage Δ
cmd/dump.go 1.03% <0.00%> (-0.02%) ⬇️
modules/indexer/code/elastic_search.go 0.00% <0.00%> (ø)
modules/indexer/code/indexer.go 35.22% <36.47%> (-0.95%) ⬇️
modules/queue/queue.go 32.25% <47.61%> (+7.86%) ⬆️
models/models.go 57.94% <71.42%> (+0.50%) ⬆️
modules/indexer/stats/db.go 52.17% <0.00%> (-8.70%) ⬇️
modules/charset/charset.go 68.53% <0.00%> (-4.50%) ⬇️
modules/log/event.go 56.60% <0.00%> (-2.84%) ⬇️
services/pull/pull.go 42.03% <0.00%> (+0.46%) ⬆️
modules/git/repo.go 50.76% <0.00%> (+0.50%) ⬆️
... and 4 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 226aef7...9a0214a. Read the comment docs.

@6543
Copy link
Member Author

6543 commented Sep 7, 2020

ready to 🚀

@zeripath zeripath merged commit cfd8e8a into go-gitea:master Sep 7, 2020
@6543 6543 deleted the dump-include-version branch September 7, 2020 23:00
6543 added a commit to 6543-forks/gitea that referenced this pull request Sep 7, 2020
* gitea dump: include version

* Check InstallLock
@6543 6543 added the backport/done All backports for this PR have been created label Sep 7, 2020
@6543
Copy link
Member Author

6543 commented Sep 7, 2020

backport -> #12762

techknowlogick pushed a commit that referenced this pull request Sep 8, 2020
* gitea dump: include version

* Check InstallLock
@go-gitea go-gitea locked and limited conversation to collaborators Nov 24, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
backport/done All backports for this PR have been created lgtm/done This PR has enough approvals to get merged. There are no important open reservations anymore. type/enhancement An improvement of existing functionality
Projects
None yet
Development

Successfully merging this pull request may close these issues.

dump: check if path to conf file is right Dump include version
5 participants