mrbaseman / parse_yaml

a simple yaml parser implemented in bash
GNU General Public License v3.0
158 stars 36 forks source link

explicit about BSD macOS support? #18

Open jcrben opened 1 year ago

jcrben commented 1 year ago

This explicitly detects GNU awk and mawk, but it doesn't say anything about BSD style awk and sed.

Are these believed to work out of the box?

Perhaps something on the readme.md mentioning the position on these.

The code could include a warning and a recommendation to install gawk (GNU awk on macOS) and gsed, and use those if available.

I may be willing to contribute improvements to do this.

mrbaseman commented 12 months ago

I'm working with Bash on Ubuntu. I might have used specific extensions of the awk and sed implementations that I have available. There is also an issue that Bash code is not always compatible with POSIX shell code (#11). In that case the changes probably would be marginal, but I didn't receive feedback in that issue. Anyhow, if you find issues on BSD, or even come up with a solution, I'd be happy to test and merge it, if it doesn't break things on linux. I even should have a FreeBSD vm somewhere...

jcrben commented 10 months ago

My solution for a macOS was to make sure that only GNU version tools were used per the helpful guide over at https://gist.github.com/skyzyx/3438280b18e4f7c490db8a2a2ca0b9da?permalink_comment_id=3049694#macos-is-a-unix-and-not-built-on-linux

I'm actually mostly on Linux myself but have teammates on MacOS

Not gonna mess around with BSD 😄