Once you have at least a basic user profile with Homebrew,
you can configure your git
.
⚙️ You can use an automated script to configure your basic git global configuration.
I use a GitHub repository mac-setup for my basic Mac setup scripts including one to configure my git globals.
If you'd like, you can use my repository to configure your git globals.
Just follow the PREREQUISITES and then Configure Your Git Globals of my GitHub repository
If you want to configure your git globals manually, you can follow these instructions.
Here you are globally configuring...
- Username
.gitignore
To configure the username globally...
git config --global user.name <github-username>
To configure the email globally...
git config --global user.email <github-emailaddress>
You will first need to CREATE a ~/.gitignore
file
that will be your global .gitignore
file.
Here is a sample .gitignore
file that you may find useful...
# Global gitignore
# Mac
.DS_Store
# IDEs
.idea/
.vscode
To configure the .gitignore
file globally...
git config --global core.excludesfile ~/.gitignore
To configure --ff-only
as the default for git pull
…
git config --global pull.ff only
To verify the configuration...
git config --list