Last active
September 28, 2025 09:25
-
Star
(284)
You must be signed in to star a gist -
Fork
(64)
You must be signed in to fork a gist
-
-
Save santisbon/a1a60db1fb8eecd1beeacd986ae5d3ca to your computer and use it in GitHub Desktop.
Revisions
-
santisbon revised this gist
Jul 21, 2025 . No changes.There are no files selected for viewing
-
santisbon revised this gist
Mar 17, 2023 . 1 changed file with 4 additions and 4 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,17 +1,17 @@ # Updating a feature branch First we'll update your local `master` branch. Go to your local project and check out the branch you want to merge into (your local `master` branch) ```bash $ git checkout master ``` Fetch the remote, bringing the branches and their commits from the remote repository. You can use the `-p`, `--prune` option to delete any remote-tracking references that no longer exist in the remote. Commits to `master` will be stored in a local branch, `remotes/origin/master`. ```bash $ git fetch -p origin ``` Merge the changes from `origin/master` into your local `master` branch. This brings your `master` branch in sync with the remote repository, without losing your local changes. If your local branch didn't have any unique commits, Git will instead perform a "fast-forward". ```bash $ git merge origin/master ``` @@ -21,7 +21,7 @@ Check out the branch you want to merge into $ git checkout <feature-branch> ``` Merge your (now updated) `master` branch into your feature branch to update it with the latest changes from your team. ```bash $ git merge master ``` -
santisbon revised this gist
Mar 17, 2023 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,6 +1,6 @@ # Updating a feature branch First we'll update your local `master` branch. Go to your local project and check out the branch you want to merge into (your local master branch) ```bash $ git checkout master ``` -
santisbon revised this gist
Mar 16, 2023 . No changes.There are no files selected for viewing
-
santisbon revised this gist
Apr 2, 2020 . No changes.There are no files selected for viewing
-
santisbon revised this gist
Jun 1, 2019 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -26,7 +26,7 @@ Merge your (now updated) master branch into your feature branch to update it wit $ git merge master ``` Depending on your git configuration this may open vim. Enter a commit message, save, and quit vim: 1. Press `a` to enter insert mode and append text following the current cursor position. 2. Press the **esc** key to enter command mode. 3. Type `:wq` to write the file to disk and quit. -
santisbon revised this gist
Jun 1, 2019 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -27,7 +27,7 @@ $ git merge master ``` Depending on your git configuration this may open vim. Enter a commit message, save, and quit vim e.g. 1. Press `a` to enter insert mode and append text following the current cursor position. 2. Press the **esc** key to enter command mode. 3. Type `:wq` to write the file to disk and quit. -
santisbon revised this gist
Jun 1, 2019 . No changes.There are no files selected for viewing
-
santisbon revised this gist
Jun 1, 2019 . No changes.There are no files selected for viewing
-
santisbon revised this gist
Jun 1, 2019 . 1 changed file with 2 additions and 2 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -27,9 +27,9 @@ $ git merge master ``` Depending on your git configuration this may open vim. Enter a commit message, save, and quit vim e.g. 1. Press `a` to enter insert mode and append text following current cursor position. 2. Press the **esc** key to enter command mode. 3. Type `:wq` to write the file to disk and quit. This only updates your local feature branch. To update it on GitHub, push your changes. ```bash -
santisbon revised this gist
Jun 1, 2019 . 1 changed file with 3 additions and 3 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -27,9 +27,9 @@ $ git merge master ``` Depending on your git configuration this may open vim. Enter a commit message, save, and quit vim e.g. 1. Press **a** to enter insert mode and append text following current cursor position. 2. Press the **esc** key to enter command mode. 3. Type **:wq** to write the file to disk and quit. This only updates your local feature branch. To update it on GitHub, push your changes. ```bash -
santisbon revised this gist
Jun 1, 2019 . 1 changed file with 4 additions and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -26,7 +26,10 @@ Merge your (now updated) master branch into your feature branch to update it wit $ git merge master ``` Depending on your git configuration this may open vim. Enter a commit message, save, and quit vim e.g. 1. Press "a" to enter insert mode and append text following current cursor position. 2. Press the esc key to enter command mode. 3. Press :wq to write the file to disk and quit. This only updates your local feature branch. To update it on GitHub, push your changes. ```bash -
asantisbon revised this gist
Jun 2, 2016 . 1 changed file with 1 addition and 4 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -26,10 +26,7 @@ Merge your (now updated) master branch into your feature branch to update it wit $ git merge master ``` Depending on your git configuration this may open vim. Enter a commit message, save, and quit vim e.g. press "a" to enter insert mode and append text following current cursor position, press Esc key to enter command mode, press :wq to write the file to disk and quit. This only updates your local feature branch. To update it on GitHub, push your changes. ```bash -
asantisbon revised this gist
Jun 2, 2016 . No changes.There are no files selected for viewing
-
asantisbon revised this gist
Jun 2, 2016 . 1 changed file with 6 additions and 5 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,13 +1,14 @@ # Updating a feature branch First we'll update your local master branch. Go to your local project and check out the branch you want to merge into (your local master branch) ```bash $ git checkout master ``` Fetch the remote, bringing the branches and their commits from the remote repository. You can use the -p, --prune option to delete any remote-tracking references that no longer exist in the remote. Commits to master will be stored in a local branch, remotes/origin/master ```bash $ git fetch -p origin ``` Merge the changes from origin/master into your local master branch. This brings your master branch in sync with the remote repository, without losing your local changes. If your local branch didn't have any unique commits, Git will instead perform a "fast-forward". -
asantisbon revised this gist
Jun 1, 2016 . 2 changed files with 36 additions and 26 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,36 @@ # Updating a feature branch First we'll update your local master branch. Go to your local project and fetch the remote, bringing the branches and their commits from the remote repository. You can use the -p, --prune option to delete any remote-tracking references that no longer exist in the remote. Commits to master will be stored in a local branch, remotes/origin/master ```bash $ git fetch -p origin ``` Check out the branch you want to merge into (your local master branch) ```bash $ git checkout master ``` Merge the changes from origin/master into your local master branch. This brings your master branch in sync with the remote repository, without losing your local changes. If your local branch didn't have any unique commits, Git will instead perform a "fast-forward". ```bash $ git merge origin/master ``` Check out the branch you want to merge into ```bash $ git checkout <feature-branch> ``` Merge your (now updated) master branch into your feature branch to update it with the latest changes from your team. ```bash $ git merge master ``` Depending on your git configuration this may open vim. Enter a commit message, save, and quit vim e.g. Press "a" to enter insert mode and append text following current cursor position Press Esc key to enter command mode Press :wq to write the file to disk and quit This only updates your local feature branch. To update it on GitHub, push your changes. ```bash $ git push origin <feature-branch> ``` This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,26 +0,0 @@ -
asantisbon revised this gist
May 30, 2016 . 1 changed file with 4 additions and 0 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -17,6 +17,10 @@ git checkout <feature-branch> # Merge your (now updated) master branch into your feature branch to update it with the latest changes from your team. git merge master # Depending on your git configuration this may open vim. Enter a commit message, save, and quit vim e.g. # Press "a" to enter insert mode and append text following current cursor position # Press Esc key to enter command mode # Press :wq to write the file to disk and quit # This only updates your local feature branch. To update it on GitHub, push your changes. git push origin <feature-branch> -
asantisbon revised this gist
May 29, 2016 . No changes.There are no files selected for viewing
-
asantisbon revised this gist
May 29, 2016 . No changes.There are no files selected for viewing
-
asantisbon created this gist
May 29, 2016 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,22 @@ # First we'll update your local master branch # cd into your local project and fetch the remote, bringing the branches and their commits from the remote repository. # You can use the -p, --prune option to delete any remote-tracking references that no longer exist in the remote. # Commits to master will be stored in a local branch, remotes/origin/master git fetch -p origin # check out the branch you want to merge into (your local master branch) git checkout master # Merge the changes from origin/master into your local master branch. # This brings your master branch in sync with the remote repository, without losing your local changes. # If your local branch didn't have any unique commits, Git will instead perform a "fast-forward". git merge origin/master # Check out the branch you want to merge into git checkout <feature-branch> # Merge your (now updated) master branch into your feature branch to update it with the latest changes from your team. git merge master # This only updates your local feature branch. To update it on GitHub, push your changes. git push origin <feature-branch>