Skip to content
This repository was archived by the owner on Jan 22, 2026. It is now read-only.
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 8 additions & 3 deletions sh/update.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
#!/bin/bash
# Updates the existing local and origin branches corresponding to the remix
# pass an argument if you want to pull a different branch name than the current branch you're on
# no argument needed to update against the branch name of the current branch

git checkout $1
git pull $1 master
git push origin $1
# branch to use is the first argument, but if the first argument was not passed, use the current git branch
branchToUse="$1" && [[ -z "$1" ]] && branchToUse="$(git rev-parse --abbrev-ref HEAD)"

git checkout $branchToUse
git pull $branchToUse master
git push origin $branchToUse