文章分类 -  git

mv the commit from one branch to another
摘要:https://dev.to/projectpage/how-to-move-a-commit-to-another-branch-in-git-4lj4 Here's a little git problem that happened to me today, which used to be 阅读全文

posted @ 2022-07-27 17:19 cdekelon 阅读(22) 评论(0) 推荐(0)

git提交时报错:Updates were rejected because the tip of your current branch is behind
摘要:https://www.jianshu.com/p/004f47f908c5 出现这样的问题是由于:自己当前版本低于远程仓库版本 有如下几种解决方法: 1.使用强制push的方法: git push -u origin master -f 这样会使远程修改丢失,一般是不可取的,尤其是多人协作开发的时 阅读全文

posted @ 2021-11-11 15:17 cdekelon 阅读(74) 评论(0) 推荐(0)

git reset , checkout branch, and pull latest code
摘要:$ git reset --hard commit-id $ git branch* dev-xxx/modfiy_value main $ git checkout main Switched to branch 'main'Your branch is up to date with 'orig 阅读全文

posted @ 2021-10-31 11:46 cdekelon 阅读(57) 评论(0) 推荐(0)

git reset --hard xxx
摘要:Install librdkafka (to enable Kafka protocol adaptor for message broker) Clone the librdkafka repository from GitHub: $ git clone https://github.com/e 阅读全文

posted @ 2021-10-23 23:14 cdekelon 阅读(39) 评论(0) 推荐(0)

How do you make changes on a specific commit
摘要:From https://confluence.atlassian.com/stashkb/how-do-you-make-changes-on-a-specific-commit-747831891.html In some unusual cases, whereby a specific co 阅读全文

posted @ 2021-08-18 16:05 cdekelon 阅读(63) 评论(0) 推荐(0)

Adding more changes to your last commit
摘要:From https://medium.com/@igor_marques/git-basics-adding-more-changes-to-your-last-commit-1629344cb9a8 Git Basics: Adding more changes to your last com 阅读全文

posted @ 2021-08-18 16:03 cdekelon 阅读(50) 评论(0) 推荐(0)

how-do-i-revert-a-git-repository-to-a-previous-commit
摘要:https://stackoverflow.com/questions/4114095/how-do-i-revert-a-git-repository-to-a-previous-commit Normally # This will detach your HEAD, that is, leav 阅读全文

posted @ 2021-01-07 18:00 cdekelon 阅读(54) 评论(0) 推荐(0)

git pull
摘要:In github, to sync latest code. $ git pull https://www.earthdatascience.org/courses/intro-to-earth-data-science/git-github/github-collaboration/update 阅读全文

posted @ 2020-09-28 14:46 cdekelon 阅读(71) 评论(0) 推荐(0)

新建branch,commit change, push to remote
摘要:$ mkdir branch$ cd branch/$ git init$ git clone https://gitlab-master.xxx.com/xxx/prelabel.gitCloning into 'prelabel'...Username for 'https://gitlab-m 阅读全文

posted @ 2019-08-27 11:57 cdekelon 阅读(215) 评论(0) 推荐(0)

Git tutorial
摘要:Git A brief overview of git: When you clone the repository you pull all the "files" and a history in the local machine. Git works by putting files int 阅读全文

posted @ 2018-12-19 10:16 cdekelon 阅读(86) 评论(0) 推荐(0)

导航