Created
October 7, 2017 20:38
-
-
Save yeled/a21c74d432d79ea96f75de43cdf4f91a to your computer and use it in GitHub Desktop.
This file contains 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
#!/bin/bash | |
# 20171007 | |
# Open in GitHub, astroidmail hook for message-view | |
# OSX only | |
# thread_view.run(hooks::github-go.sh %2)=G | |
ID=$1 | |
FILE=$(notmuch search --output=files id:"$ID") | |
URL=$(for i in $FILE ; do | |
grep -iA1 'View it on GitHub:' $i |tail -1 | |
done) | |
open $URL |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment