Skip to content

Instantly share code, notes, and snippets.

@mecaneer23
Created June 19, 2024 20:34
Show Gist options
  • Save mecaneer23/f88812f9c75b50d0550554a5ac3d87c7 to your computer and use it in GitHub Desktop.
Save mecaneer23/f88812f9c75b50d0550554a5ac3d87c7 to your computer and use it in GitHub Desktop.
Run in a git directory to print the most recent github commit link for that directory
get-recent-commit-url() {
echo "$(git remote get-url origin)/commit/$(git log -n 1 | grep commit | awk '{print $2}')"
}
get-recent-commit-url
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment