Last active
May 26, 2026 15:46
-
-
Save assertnotnull/d16fbf6439999acb0bcd0718de805ff9 to your computer and use it in GitHub Desktop.
Fish shell: git town propose with PR renamed
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 characters
| function branch-title | |
| set -l branch $argv[1] | |
| if test -z "$branch" | |
| set branch (git branch --show-current) | |
| end | |
| echo $branch | sed -E \ | |
| 's|^([^/]+)/([a-zA-Z]+)-([0-9]+)-(.*)$|\1(\U\2\E-\3): \L\4|; s|-| |g; s|\(([A-Z]+) ([0-9]+)\)|(\1-\2)|' | |
| end |
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 characters
| function gpr | |
| branch-title | xargs -I {} git propose -t {} | |
| end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment