Skip to main content
  1. Learn center
  2. Software Development
  3. Guides
  4. Git tutorial
  5. How to use Git
  6. How to use Git on Command Line
  7. Default settings
GuidesSoftware DevelopmentBacklog
Git

Project and code management together.

Default settings

Next, set your default username and e-mail address so that Git can identify the person committing changes.

This setup only needs to be done once.

The Git console configuration is saved in the .gitconfig file in the user’s home directory. You can manually edit the file, but we will use the git config command in this tutorial.

$ git config --global user.name ""
$ git config --global user.email ""

Set the Git output color.

$ git config --global color.ui auto

You can also set aliases for Git commands. For instance, you can abbreviate checkout to co to execute the command.

$ git config --global alias.co checkout

Windows only

If you use Console (Git Bash) on Windows, a file name containing non-ASCII characters will be displayed in a form like \346\226\260\350\246…, We can configure it to allow the file to display the file name as it is by doing the following:

$ git config --global core.quotepath off

If you use Console on Windows, you can only use ASCII characters.

Accordingly, to include multi-byte characters in a commit message, you must set an external editor and not use the -m option.

External editors should be compatible with the character code UTF-8 and line feed code LF.

git config --global core.editor "\"[path of the editor you use]\"" git config --global core.editor "\"[path of the editor you use]\""

Setup is complete! Now we can get to work.

Subscribe to our newsletter

Learn with Nulab to bring your best ideas to life