Thursday, May 19, 2022

Configure your Git username/email

Ref:https://support.atlassian.com/bitbucket-cloud/docs/configure-your-dvcs-username-for-commits/ 

Configure your Git username/email

You typically configure your global username and email address after installing Git. However, you can do so now if you missed that step or want to make changes. After you set your global configuration, repository-specific configuration is optional.

Git configuration works the same across Windows, macOS, and Linux.

To set your global username/email configuration:

  1. Open the command line.

  2. Set your username:
    git config --global user.name "FIRST_NAME LAST_NAME"

  3. Set your email address:
    git config --global user.email "MY_NAME@example.com"

To set repository-specific username/email configuration:

  1. From the command line, change into the repository directory.

  2. Set your username:
    git config user.name "FIRST_NAME LAST_NAME"

  3. Set your email address:
    git config user.email "MY_NAME@example.com"

  4. Verify your configuration by displaying your configuration file:
    cat .git/config

No comments:

Post a Comment

Install and use xorg-server on macOS via Homebrew

  The instructions to install and use xorg-server on macOS via Homebrew: Install Homebrew (if you haven't already): /bin/bash -c ...