mbrukman / autogen

Automatically generate boilerplate license comments.
Apache License 2.0
98 stars 27 forks source link

Swap `autogen` and `autogen.sh` (again) #68

Closed mbrukman closed 5 years ago

mbrukman commented 5 years ago

This change reverses the original swap, which originally moved all the content of autogen.sh into autogen and made autogen.sh a simple wrapper that simply called autogen with the same parameters.

The rationale back then for moving autogen.sh to autogen was to enable easy replacement of the implementation, should we want to rewrite the shell script in a Python script, say, but this way, no one would need to change their scripts.

However, we will be moving to Go instead of Python, and we want to keep the binary the same name, autogen. To make it possible to replace the shell script with the Go binary, we need to have them coexist so that we can do parallel testing with both the shell script and the Go binary.

Building the Go binary in the source tree replaces the current autogen shell script with the autogen native binary, which makes it hard to easily test our code since autogen is the canonical shell script today.

This change makes autogen.sh the canonical shell script which can be easily tested via automated means, and in the future, we will also test autogen directly, which will be the native Go binary rather than a shell script.

At some point in the future, we will remove the shell scripts entirely, and users will be building the binary directly from Go source code.