Page MenuHomePhabricator

MediaWiki-Vagrant submodules are set up with absolute paths
Open, LowPublic

Description

vagrant@mediawiki-vagrant:/vagrant$ git status
fatal: Not a git repository: /home/gtisza/Wikimedia/vagrant/TemplateStyles/.git/modules/puppet/modules/cdh

Caused by the puppet submodules' .git files containing that path (three of the four, anyway - the fourth one contained the absolute guest path).

Brand new box, I don't rememeber doing anything funny during setup. According to my bash history, it was created with git clone --recursive https://gerrit.wikimedia.org/r/mediawiki/vagrant .. Is it possible git behavior changed recently and it is now using absolute submodule paths where it used to use relative ones?

Event Timeline

One-line fix is

sed -i 's/^gitdir: .*\(\.git\/modules\/puppet\/.*\)$/gitdir: ..\/..\/..\/\1/' /vagrant/puppet/modules/*/.git

(no idea if that's the best way to fix it but it works)

Tgr renamed this task from Git on vagrant guest sees host repo path to MediaWiki-Vagrant submodules are set up with absolute paths.Dec 12 2016, 11:19 PM
Tgr updated the task description. (Show Details)
Aklapper triaged this task as Low priority.Dec 6 2022, 10:26 AM