Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Swap out Makefile with Go scripts #45

Closed
jbduncan opened this issue Sep 18, 2024 · 0 comments
Closed

Swap out Makefile with Go scripts #45

jbduncan opened this issue Sep 18, 2024 · 0 comments

Comments

@jbduncan
Copy link
Owner

jbduncan commented Sep 18, 2024

This is an experiment to see how far I can go with using Go to script everything, similar to Rust's approach to using an x.py script.

This is done partly out of fun and partly to allow linting to run tools concurrently without resorting to Bash trickery or installing GNU parallel (though it may be adopted anyway if Nix is adopted as a way of managing consistent versions of various tools).

Follow a similar approach to https://blog.kowalczyk.info/article/4b1f9201181340099b698246857ea98d/using-go-instead-of-bash-for-scripts.html.

However, make sure to use go build and run the script binary directly because the docs for go run say,

The exit status of Run is not the exit status of the compiled binary.

Consider using https://github.com/bitfield/script, the u-root userland binaries or Nix to use consistent and reproducible versions of any Unix tools that may be needed.

Related: #27.

jbduncan added a commit that referenced this issue Sep 29, 2024
This is an experiment to see how far I can go with using Go to
script everything, similar to Rust's approach to using an `x.py`
script.

This is done partly out of fun and partly to allow linting to run
tools concurrently without resorting to Bash trickery or
installing GNU parallel (though it may be adopted anyway if Nix is
adopted as a way of managing consistent versions of various tools).

Issue: #45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant