[b]git将已经存在的目录添加到远程的版本库命令[/b]
[b]git在linux上使用[/b]
[b]有了项目有需要执行打包,排除test和选择profile[/b]
[b]切换分支[/b]
[b]menge分支[/b]
[b]在使用时候遇到的问题[/b]
[i]1.linux遇到http406:添加到.netrc配置[/i]
http://git.XX.com/aroundair/air-insurance
Existing folder or Git repository
cd existing_folder
git init
git remote add origin git@git.jd.com:aroundair/air-insurance.git
git add .
git commit
git push -u origin master
[b]git在linux上使用[/b]
//配置ssh,在本地生成ssh的pub,放到git的服务器上
ssh-keygen -t rsa -C "GitLab" -b 4096
在git服务上克隆某个分支的代码
git clone -b 分支1 //clone某个分支
git branch -a //所有分支
git branch //当前分支
git pull origin 分支 //fetch menge
[b]有了项目有需要执行打包,排除test和选择profile[/b]
mvn clean package -Dmaven.test.skip=true -Pdevelopment
[b]切换分支[/b]
git checkout 分支
[b]menge分支[/b]
git merge origin/分支
[b]在使用时候遇到的问题[/b]
[i]1.linux遇到http406:添加到.netrc配置[/i]
machine source.xx.com
login Janle
password Janle88888