Skip to content

Instantly share code, notes, and snippets.

@MadsAkselsen
Last active November 8, 2023 09:43
Show Gist options
  • Select an option

  • Save MadsAkselsen/627040adaeffbfe7ab0bf885c483b4c7 to your computer and use it in GitHub Desktop.

Select an option

Save MadsAkselsen/627040adaeffbfe7ab0bf885c483b4c7 to your computer and use it in GitHub Desktop.
print_newest_git_branches
newest_git_branches() {
git fetch --all
git for-each-ref --sort=-committerdate refs/heads/ refs/remotes/ --format='%(committerdate) %09 %(refname:short)'
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment