跳过正文
Background Image
  1. Posts/

Git 命令备忘

·188 字·1 分钟· ·
沈显鹏
作者
沈显鹏

有些git命令总是记不住,在我这台 Ubuntu 使用 web 版 OneNote 不方便,那就把他们记到 Blog 里吧,需要的时候翻看一下。

git remote

git remote -v                 # 查看当前位置的远程代码库

git remote remove origin      # 取消远程仓库
git remote add orgin git@github.com:shenxianpeng/nightwatch.git       # 关联新的仓库

git log

# 得到某一时段提交日志
git log --after='2017-12-04' --before='2017-12-08' --author=xshen --pretty=oneline --abbrev-commit

git tag

git tag -a v1.6.700 -m 'Release v1.6.700'

# 给前面的提交补上 tag
git log --pretty=oneline
git tag -a v1.6.700 -m 'Release v1.6.700' e454ad98862

git push tag
git push origin --tag

设置 npm install 代理

npm config set proxy=http://10.17.201.60:8080       # 设置代理
npm config set proxy null                           # 取消代理

设置 cnpm

npm install -g cnpm --registry=https://registry.npm.taobao.org
cnpm install [name]
cnpm sync connect
cnpm info connect

相关文章

Git remove and add remote repository
·63 字·1 分钟
本文介绍了如何在 Git 中移除和添加远程仓库,帮助开发者管理代码仓库的远程连接。
Nightwatch 使用 VS code 进行调试
·86 字·1 分钟
本文介绍如何配置 VS Code 来调试 Nightwatch 测试代码,提供了详细的配置示例和步骤。
Nightwatch 持续集成问题
·411 字·1 分钟
介绍如何在 Nightwatch 持续集成中处理自动化测试用例的常见问题,包括运行时间过长、程序卡住和异常处理。
Nightwatch 打开多个窗口
·50 字·1 分钟
如何在 Nightwatch 中打开多个浏览器窗口并切换控制。