vet / help

:question: Automatic help command for your scripts directory
MIT License
2 stars 0 forks source link

Get description via awk #2

Open BrandonRomano opened 7 years ago

BrandonRomano commented 7 years ago

@hhsnopek the strategy you were using does not support this case:

// ## This is a description here of my JS script

The old code was this:

description="$(awk '/\#\#\ .*/{ print $0 }' ${file})"

I reverted back to my strategy so we have something working right now, but if we want to get awk back in feel free to address that case and plug it back in!

hhsnopek commented 7 years ago

haha cool - yeah I just wanted to get it done with a single util rather than many 🙃

BrandonRomano commented 7 years ago

I am in agreement if it's possible - I'm just not good with awk, so I'll need you to look into it!