Wrong hint when pushing the wiki of a moved repository
Summary
When pushing to the old origin of a repository that has been moved, GitLab gives a hint on how to update to the new origin. When pushing to the wiki of a moved repository, the new origin points to the repository itself and not to the wiki.
Steps to reproduce
- Create a repository
- Clone the wiki
- Move the repository to another namespace
- Try pushing to the wiki via the repository cloned in
2.
What is the current bug behavior?
GitLab gives the following hint:
GitLab: Project '<owner>/<repo>.wiki' was moved to '<owner>/<namespace>/<repo>'.
Please update your Git remote and try again:
git remote set-url origin ssh://git@<hostname>/<owner>/<namespace>/<repo>.git
What is the expected correct behavior?
The provided hint should point to the wiki repository:
GitLab: Project wiki '<old-path>/-/wikis' was moved to '<new-path>/-/wikis'.
Please update your Git remote and try again:
git remote set-url origin ssh://git@<hostname>/<owner>/<namespace>/<repo>.wiki.git
Results of GitLab environment info
Expand for output related to GitLab environment info
System information System: Ubuntu 16.04 Current User: git Using RVM: no Ruby Version: 2.3.5p376 Gem Version: 2.6.13 Bundler Version:1.13.7 Rake Version: 12.1.0 Redis Version: 3.2.5 Git Version: 2.13.6 Sidekiq Version:5.0.4 Go Version: unknownGitLab information Version: 10.1.2 Revision: af60a6c Directory: /opt/gitlab/embedded/service/gitlab-rails DB Adapter: postgresql Using LDAP: no Using Omniauth: no
GitLab Shell Version: 5.9.3 Repository storage paths:
- default: /var/opt/gitlab/git-data/repositories Hooks: /opt/gitlab/embedded/service/gitlab-shell/hooks Git: /opt/gitlab/embedded/bin/git
Test Activity
- Add/update test for this case.
MR Breakdown
- This is probably related to GitAccess
Edited by 🤖 GitLab Bot 🤖