linux - Regex remove comments but not shebang -


i got regex removes comments in bash using regex code

'/^\#/d' 

but removes #! should not because it's not comment tag shebang

so how can done ignore #! in regex?

this line remove every comment starting # not followed !.

'/^#[^!]/d' 

Comments

Popular posts from this blog

linux - Does gcc have any options to add version info in ELF binary file? -

android - send complex objects as post php java -

charts - What graph/dashboard product is facebook using in Dashboard: PUE & WUE -