- Spaces clones lmatheson4/dotfile-bootstrap@main
- Spaces invokes
./install.shin that tree install.shadds a remote to Stabledog/dotfiles-spaces@main asghmineinstall.shfetches, then checks outghmine/main- No
install-inner.shis available, soinstall.shinvokes it.
Important
Stabledog/dotfiles-spacesandlmatheson4/dotfile-bootstrapare the SAME repo logically. But their main branches are permanently different and should not be reconciled or cross-merged.
The lmatheson4/dotfile-bootstrap@main is a thin bootloader for the Stabledog/dotfiles-spaces@main
The two upstreams do share a bit of content:
README.md
jumpstart.bashrc
.vscode/* # Inclues snippets, tasks.json, settings.json, etc
This is necessary because Spaces uses a "magic" VS Code settings propagation extension, and that content must be present in the origin upstream. But it's also needed in ghmine for general use.
This means there is manual maintenance such that when you change one of these shared files, it's important to commit changes to both upstreams , e.g.:
# After editing a shared file in the working copy, commit and push to one of the remotes:
git add foo.txt
git commit -m "Updated foo.txt" && git push origin HEAD:main
# Checkout ghmine/main, then overlay changed files from origin/main
./git-pseudo-merge ghmine/main origin/main
#... reconcile, commit, and push. Reverse the remotes and do it again if there are changes on both remotes.
The unusual branch architecture requires care when making changes.
Never do maintenance on a local main branch. (Tip: Just don't ever create a local main branch)
Normally this is checked out in the working copy, so simply edit the files and commit/push the detached HEAD to ghmine:
git add . && git commit -m "changed something for ghmine"
git push ghmine HEAD:main
-
Check this out first:
git checkout origin/mainto get a detached HEAD -
Edit files
-
Commit and push:
git add . && git commit -m "changed something for origin"
git push origin HEAD:main
# Restore normal state:
git checkout ghmine/main