
git
yanchengyc
这个作者很懒,什么都没留下…
展开
-
git clone branch的项目
例如项目rails_test主干为master提交一个分支(branch)为:zqalycgit clone git@fitark.org:rails/rails_test.git 默认clone的是master的项目git clone -b zqalyc git@fitark.org:rails/rails_test.git 是clone分支的项目原创 2013-10-21 21:08:19 · 723 阅读 · 0 评论 -
删除git版本控制下的.idea目录
The full process would look like this:$ echo '.idea' >> .gitignore$ git rm -r --cached .idea$ git add .gitignore$ git commit -m '(some message stating you added .idea to ignored entries)'$ git p转载 2014-03-05 21:43:40 · 3397 阅读 · 0 评论 -
解决git提交报错:fatal: remote origin already exists.
1. git remote rm origin2. git init 3. g原创 2014-07-18 17:09:08 · 1258 阅读 · 0 评论 -
github常见操作和常见错误!错误提示:fatal: remote origin already exists.
如果git remote add origin git@github.com:xxx/xxx.git 提示出错信息:fatal: remote origin already exists. 或者 fatal: 远程 origin 已经存在 解决办法:git remote rm origin原创 2017-02-20 17:51:44 · 999 阅读 · 0 评论 -
git仓库删除所有提交历史记录,成为一个干净的新仓库
把旧项目提交到git上,但是会有一些历史记录,这些历史记录中可能会有项目密码等敏感信息。如何删除这些历史记录,形成一个全新的仓库,并且保持代码不变呢?1.Checkout git checkout --orphan latest_branch2. Add all the files git add -A3. Commit the changes git commit -am "commi原创 2017-02-22 16:12:57 · 42001 阅读 · 9 评论