guumaster / hostctl

Your dev tool to manage /etc/hosts like a pro!
http://guumaster.github.io/hostctl
MIT License
1.04k stars 45 forks source link

Preventing comments from getting into entries #74

Closed kadern0 closed 2 years ago

kadern0 commented 3 years ago

Signed-off-by: Pablo Caderno kaderno@gmail.com

Fixes issue #72

I've also removed the spaceRemover and tabReplacer since strings.TrimSpace() should get rid of either of these.

guumaster commented 3 years ago

Thanks @kadern0 for this PR, I'll check it as soon as I can create a new release.

guumaster commented 3 years ago

Thanks for your contribution @kadern0. I'm reviewing this, but tabReplacer and spaceRemover also takes care of extra spaces and tabs inside the lines, not only on leading and trailing characters. Could you restore that before merging?

kadern0 commented 2 years ago

Done!