Last active
July 1, 2016 13:13
-
-
Save criztovyl/3fd22e3ed8158faf0ec3 to your computer and use it in GitHub Desktop.
Tries to display the description line of a GPLed file.
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
gpl-comment() | |
{ | |
[[ "$1" =~ ^-{0,2}h(elp)?$ ]] && { echo -e "Tries to display the description line of a GPLed file.\nUsage: gpl-comment file"; return 0; } | |
echo $(head -n2 $1 | tail -n1 | sed 's/^\W \?//') | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment