git config all in one
2024-09-08 07:32:59
git config
git global config
# git global config
$ git config
$ git config --list --show-origin
$ git config --global user.name "xgqfrms"
$ git config --global user.email "xgqfrms@xgqfrms.xyz"
# $ git config --global core.editor emacs
$ git config --global core.editor vscode
$ git config --global core.editor "'C:/Program Files/Notepad++/notepad++.exe' -multiInst -notabbar -nosession -noPlugin"
vscode
$ code ~/.gitconfig
$ code .git/config
[filter "lfs"]
clean = git-lfs clean -- %f
smudge = git-lfs smudge -- %f
process = git-lfs filter-process
required = true
[user]
name = xgqfrms
email = xgqfrms@xgqfrms.xyz
[core]
excludesfile = /Users/xgqfrms-mbp/.gitignore_global
[difftool "sourcetree"]
cmd = opendiff \"$LOCAL\" \"$REMOTE\"
path =
[mergetool "sourcetree"]
cmd = /Applications/Sourcetree.app/Contents/Resources/opendiff-w.sh \"$LOCAL\" \"$REMOTE\" -ancestor \"$BASE\" -merge \"$MERGED\"
trustExitCode = true
[commit]
template = /Users/xgqfrms-mbp/.stCommitMsg
$ git config --global user.name "xgqfrms"
$ git config --global user.email "xgqfrms@xgqfrms.xyz"
$ git config user.name "xgqfrms"
$ git config user.email "xgqfrms@xgqfrms.xyz"
git local config
.git/config
# local config
$ git config --local -l
# edit
$ git config --local -e
$ cd .git
$ code .
$ git config user.name "your-user-name"
$ git config user.email "your-email-addr"
$ git config user.name "webgeeker"
$ git config user.email "webgeeker@webgeeker.xyz"
git
https://www.atlassian.com/git/tutorials/setting-up-a-repository/git-config
https://git-scm.com/docs/git-config
github
https://help.github.com/en/articles/setting-your-username-in-git
https://help.github.com/en/articles/set-up-git
git cconfig
https://www.shellhacks.com/git-config-username-password-store-credentials/
filename & lowercase
http://www.ruanyifeng.com/blog/2017/02/filename-should-be-lowercase.html
git cli & create remote branch
# Create a new branch and check it out
$ git checkout -b <branch-name>
# The remote branch is automatically created when you push it to the remote server.
# <remote-name> is typically origin
$ git push <remote-name> <branch-name>
$ git push <remote-name> <local-branch-name>:<remote-branch-name>
$ git push --set-upstream <remote-name> <local-branch-name>
# create a new branch & check it out
$ git checkout -b test
# local & remote with the same name
$ git push origin test
# local & remote with a different name
$ git push origin test:dev
# delete remote brach bug, if only `:<remote-branch-name>`
$ git push origin :dev
https://tecadmin.net/how-to-create-a-branch-in-remote-git-repository/
https://stackoverflow.com/questions/1519006/how-do-you-create-a-remote-git-branch
refs
xgqfrms 2012-2020
www.cnblogs.com 发布文章使用:只允许注册用户才可以访问!
最新文章
- MSP430FR4133/4131/4132单片机破解芯片解密多少钱?
- ubuntu下安装mysql
- 在ECSHOP后台左侧导航中增加新菜单
- 【转】SQL注入(通过sqlmap来改变所有事情)
- URAL 2073 Log Files (模拟)
- Oracle DB 通过 Oracle Enterprise Manager注册要使用的恢复目录
- PS5穿越云层3D文字
- 帝国cms7.0整合百度编辑器ueditor教程
- c vs c++ in strcut and class
- SQL联表查询
- 【朝花夕拾】朝花夕拾-Robot Framework实战演练之开篇
- linux系统的磁盘空间限制的两种方法
- 学习笔记-echarts x,y轴样式
- python接口自动化(二十五)--unittest断言——下(详解)
- 【错误解决】Intellj(IDEA) warning no artifacts configured
- 25个SSH命令
- springboot下多线程开发注意事项
- jq ajax传参的两种方式
- maven parent工程.pom修改后未自动更新
- VIM命令图解
热门文章
- WPF和MVVM的结合使用方法,不可错过
- LOJ10081
- new的过程是怎样的?看完这一篇就懂了
- (19)ln命令:在文件之间建立链接(硬链接和软链接)
- go语言常见面试题
- php之魔术方法 __set(),__get(),__isset(),__unset()
- Java正则表达式解析网页源码
- Maven三种打包方式jar war pom
- Codeforces Round #604 (Div. 2) A. Beautiful String(贪心)
- 【noi 2.6_8787】数的划分(DP){附【转】整数划分的解题方法}