tomnomnom / anew

A tool for adding new lines to files, skipping duplicates
MIT License
1.34k stars 147 forks source link

Add help message for "-h" and "--help" #2

Closed leesoh closed 4 years ago

leesoh commented 4 years ago

anew will only return usage instructions when used with no arguments. This adds support for "-h" and "--help". Everything I tested on my end works as expected, but I was working from https://stackoverflow.com/questions/28091963/golang-flag-library-unable-to-override-usage-function-that-prints-out-command-l and am still wrapping my head around what it's doing so you might want to double-check that I haven't done something stupid :)

leesoh commented 4 years ago

This is a silly PR. I am going to close it.