Skip to content

Instantly share code, notes, and snippets.

@cpu-meltdown
Last active May 16, 2023 18:41
Show Gist options
  • Save cpu-meltdown/0fde78cc31f7d7dd11bd1f703bcf9d89 to your computer and use it in GitHub Desktop.
Save cpu-meltdown/0fde78cc31f7d7dd11bd1f703bcf9d89 to your computer and use it in GitHub Desktop.
Useful terminal commands
Find list of files that contain a certain value: grep -iRl “value here“ ./
Delete all branches that start with a certain prefix: git branch | grep "value here" | xargs git branch -D
alias gco='command git checkout'
gcot() {
cd "workspace"
git branch | grep "$1" | xargs git checkout
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment