addlicense, a tool to automate license headers

For the past few months I have been toying around Standard ML and after some work I pushed my testing library’s, Railroad, first release.

Considering that I wanted to make it single file and that I also have some tests there. It would be nice to have an automated way to add and update license headers on the source files.

After a brief search, I discovered addlicense. This is a tool that does exactly what I wanted: add and update license headers. That’s it.

This is how I used it on my project:

addlicense \
  -c "Perplex Systems" \
  -l apache \
  $(find . -type f -iregex ".*\.\(sml\|smi\|sig\|mlb\)$")

Easy, isn’t it? Just say who you are, feed it the files you want to modify and that’s it!

Unsupported file extensions

If, like me, you are using it with a not so common file extension. The tool will fail silently, in this case, I recommend you take a look and see if your file extension is supported on its source code.

I forked it to introduce the Standard ML file extensions and I also plan on having it update the license headers.

Articles from blogs I follow around the net

Trimming a Fake Object

A refactoring example. When I introduce the Fake Object testing pattern to people, a common concern is the maintenance burden of it. The point of the pattern is that you write some 'working' code only for test purposes. …

via ploeh blog November 20, 2023

Building a digital vigil for those we've lost

This post is hard to write in a lot of ways. It's more personal than most I've written. This is presumptively a tech blog, and this piece is about so much more than technology. But it's important. Making things, software or otherwise, is ultimatel…

via blog November 19, 2023

#122 Experimenting and Learning

Update on what happened across the GNOME project in the week from November 10 to November 17. GNOME Circle Apps and Libraries Workbench A sandbox to learn and prototype with GNOME technologies. Sonny says Workbench is a code playground and Library to learn, e…

via This Week in GNOME November 17, 2023

Generated by openring