Configuration for one command only

suggest change

You can use -c <name>=<value> to override a configuration value for one command.

To commit with a different email without changing .gitconfig:

git -c user.email=mail@example.com commit -m "some message"

Note: for that example you can override just user.email or just user.name. The other value still comes from your configuration, not from earlier commits. There must be no spaces around =.

Feedback about page:

Feedback:
Optional: your email if you want me to get back to you:



Table Of Contents