|
|
|
|
|
by mixmastamyk
648 days ago
|
|
I use git and and a hub site: - Create repo in ~ with a few dot files, push - Make a new system setup script, run on other machine: # install git; cd ~
# I use a read-only token, optional:
git clone "https://x-token-auth:${TOKEN}@bitbucket.org/you/dot_repo.git" dot_repo
# move into $HOME
cp -afv dot_repo/. .
rm -rf dot_repo
git config --local status.showUntrackedFiles no
Later on, if I want to write to the repo on this machine I run ssh-keygen, copy the public key to the remote and remove the token from .git/config and use ssh access instead.I used to have everything excluded in .gitignore and force add files to the repo, but prefer status.showUntrackedFiles instead. There are still a few edge cases but they don't bother you everyday like having to force every operation. Some of my scripts have things like, if dist fedora, do this, else debian, do this, else Mac, do that, when they differ. |
|