- gitlab-ctl start # 启动所有 gitlab 组件;
- gitlab-ctl stop # 停止所有 gitlab 组件;
- gitlab-ctl restart # 重启所有 gitlab 组件;
- gitlab-ctl status # 查看服务状态;
- gitlab-ctl reconfigure # 启动服务;
- vim /etc/gitlab/gitlab.rb # 修改默认的配置文件;
- gitlab-rake gitlab:check SANITIZE=true --trace # 检查gitlab;
- gitlab-ctl tail # 查看日志;
- git version #查看版本;
- git add xxx #新建;
- git status #查看状态;
- git commit -m "xxx" #提交
- git push -u origin master #推送
- git branch xxx #创建分支
- git checkout xxx #分支切换
- git checkout -b xxx #实现创建+切换
- git branch #查看当前活动分支(*代表当前活动的分支)
- git push origin --delete xxx #删除分支
- git branch -v #查看远程分支
- git merge xxx(分支)--no-ff
- 使用no-ff选项进行合并可以将comment一起转移,能够清晰的看出从哪儿来,做了哪些改变。
merge之前的log. ff是fast forward的缩写,ff方式在合并时不会生成一个新的合并节点,而no-ff则会生成。所以一般来说使用no-ff在管理起来更加方便。
GitLab常用命令
最新推荐文章于 2024-05-11 11:18:37 发布