I was browsing through the source code of Tom Christie’s typesystem1 library and discovered that the shell scripts2 of the project don’t have any extensions attached to them. At first, I found it odd, and then it all started to make sense.
Executable scripts can be written in any language and the users don’t need to care about that. Also, not gonna lie, it looks cleaner this way.
GitHub uses this [pattern]3 successfully to normalize their scripts. According to the
pattern, every project should have a folder named scripts
with a subset or superset of the
following files:
script/bootstrap
– installs/updates all dependenciesscript/setup
– sets up a project to be used for the first timescript/update
– updates a project to run at its current versionscript/server
– starts appscript/test
– runs testsscript/cibuild
– invoked by continuous integration servers to run testsscript/console
– opens a console
— ⁂ —
Recent posts
- Why does Go's io.Reader have such a weird signature?
- Go slice gotchas
- The domain knowledge dilemma
- Hierarchical rate limiting with Redis sorted sets
- Dynamic shell variables
- Link blog in a static site
- Running only a single instance of a process
- Function types and single-method interfaces in Go
- SSH saga
- Injecting Pytest fixtures without cluttering test signatures