dot-slash-go: Simple Project ./go Scripts
I 💛 ./go scripts.
I make it a point to include ./go scripts in every project I work on. A ./go script will significantly increase new developer productivity. Any open source project looking to lower their barrier of entry should adopt one.
Since I value them so much, I created
dot-slash-go, an extendible, friendly framework for project ./go scripts. It enables you to create a better developer experience with less effort.
./go scripts tend toward a general implementation. They define a set of commands as functions. Passing no arguments displays help output enumerating the commands and their usage. This boilerplate is tedious to create for every new repository.
The ./go script user experience is important. Working with multiple teams I’ve encountered a variety of usability. Some teams do an excellent job outputting helpful command usage information. Others stop at surfacing the command and leave you guessing at what they do or what arguments are supported.
dot-slash-go to eliminate the boilerplate and encourage improved usability. Creating and documenting commands is so simple you’ve got no excuse to skip it!
Installation is a breeze. Navigate to your project root and run the following command:
bash -c "$(curl -sS https://raw.githubusercontent.com/bromanko/dot-slash-go/master/install)"
A guided process will ask you a series of questions to create a
./go shell script and a
.go folder to store metadata and commands.
Re-running the install script is safe. It will update
./go to the latest version and will not delete any of your customizations.
Creating new commands is also simple. Just use the included command command.
Creating a dot-slash-go command
The new build command, contextual help and usage information can be modified by editing
dot-slash-go a shot. Let me know what you think, open an issue, or improve it via a pull-request. Enjoy!