1. branch for fixing issue
1 | git checkout -b fix-bug |
2. Pull a remote branch
Ensure in advance that you ref all branches in .git/config
, then
1 | git fetch --all |
A successful example:
3. prevent typing password in http protocol
3.1 Git Credential store
1 | git config --global credential.helper store |
After enabling this you will be prompted for your creds on your next commit. your token will be stored in plain text in ~/.git-credentials
.
3.2 Microsoft Git Credential Manager
Step 1: aur install git-credential-manager-core-bin
developed by Microsoft then config:
1 | git-credential-manager-core configure |
Step 2: For Linux system, a default strategy for storing credential passwords doesn’t exist. So one of the four options of storing credentials should be configured by setting the GCM_CREDENTIAL_STORE
environment variable or credential.credentialStore
git configuration setting.
environment variable way:
1 | export GCM_CREDENTIAL_STORE=secretservice # secretservice / gpg / cache / plaintext |
Or
1 | git config --global credential.credentialStore secretservice # secretservice / gpg / cache / plaintext |
四、IDEA中的图形化git操作
4.1 git commit
在菜单栏找到git > commit
点击进入窗口
确认无误,点击commit后,IDEA还会帮你check一下更改文件的代码语法与警告。
评论
shortname
for Disqus. Please set it in_config.yml
.