I'm updating this all the time... :)
This is what I use and keep my computers in sync with similar config.
To install everything, just run:
make install
will install Homebrew (and Xcode if MacOS), Brewfile packages, stow dotfiles into place, and some additional post commands.
For convenience:
make stow
will do the dotfiles stowing only.
make brew
will do the Brew package installing only.
Create a .gitconfig in home folder that looks something like this
[user]
email = [email protected]
name = My Name
[init]
defaultBranch = master
[help]
autocorrect = 1
[core]
sshCommand = ssh -i ~/.ssh/mykey
editor = nvim
[includeIf "gitdir:~/other/identity/"]
path = ~/other/identity/.gitconfig
And then add a similar .gitconfig in the dir where you want to override values.