This page (revision-22) was last changed on 13-Oct-2021 18:43 by arcoleo

This page was created on 31-Mar-2020 17:25 by arcoleo

Only authorized users are allowed to rename pages.

Only authorized users are allowed to delete pages.

Page revision history

Version Date Modified Size Author Changes ... Change note
22 13-Oct-2021 18:43 1 KB arcoleo to previous
21 13-Jul-2021 19:34 1 KB arcoleo to previous | to last

Page References

Incoming links Outgoing links
Git Branch Usage ...nobody

Version management

Difference between version and

At line 7 changed one line
!! Checkout your branch
|| Description || Zsh || Git
| Checkout branch | {{{gco $branch_name}}} | {{{git checkout $branch_name}}}
| Rebase your branch from HEAD[1] | {{{grbi HEAD~$Y}}} | {{{git rebase -i HEAD~$Y}}}
| Force push your branch | {{{ggfl}}} | {{{git push
--force-with-lease
origin $current_branch}}}
At line 9 changed 4 lines
{{{
omz> gco $branch_name
zsh> git checkout $branch_name
}}}
[#1] {{$Y}} is displayed in GitLab at the top, where it says ''Overview: X, Commits: Y, Pipelines: Z, ...'' . The number you want is Y.
At line 14 removed 20 lines
!! Rebase your branch from HEAD
{{$number_of_commits}} is displayed in GitLab at the top, where it says
Overview: X, Commits: Y, Pipelines: Z, ...
The number you want is Y.
{{{
omz> grbi HEAD~5
zsh> git rebase -i HEAD~$number_of_commits
}}}
!! Force push your branch
{{{
omz> ggfl
zsh> git push --force-with-lease origin $current_branch
}}}
At line 38 changed one line
!! Checkout master
|| Description || Zsh || Git
| Checkout master | {{{gcm}}} | {{{git checkout master}}}
| Pull | {{{gl}}} | {{{git pull}}}
| Checkout branch | {{{gco $branch_name}}} | {{{git checkout $branch_name}}}
| Rebase from master | {{{grbm}}} | {{{git rebase master}}}
| Handle conflicts, test, etc.
| Force push {{{$current_branch}}} to remote | {{{ggfl}}} | {{{git push
--force-with-lease
origin $current_branch}}}
At line 40 removed 37 lines
{{{
omz> gcm
zsh> git checkout master
}}}
!! Pull
{{{
omz> gl
zsh> git pull
}}}
!! Checkout branch
{{{
omz> gco $branch_name
zsh> git checkout $branch_name
}}}
!! Rebase from master
{{{
omz> grbm
zsh> git rebase master
}}}
Handle conflicts, test, etc.
!! Force push
Force push {{$current_branch}} to remote.
{{{
omz> ggfl
zsh> git push --force-with-lease origin $current_branch
}}}
At line 81 changed one line
!! Checkout master
|| Description || Zsh || Git
| Checkout master | {{{gcm}}} | {{{git checkout master}}}
| Merge feature branch into master | {{{gm $feature_branch}}} | {{{git merge $feature_branch}}}
| Push master| {{{ggp}}} | {{{git push origin master}}}
At line 83 removed 19 lines
{{{
omz> gcm
zsh> git checkout master
}}}
!! Merge feature branch into master
{{{
omz> gm $feature_branch
zsh> git merge $feature_branch
}}}
!! Push master
{{{
omz> ggp
zsh> git push origin master
}}}