France’s laws are now on GitHub

A new repository traces the entire change history of France’s civil codes going back to the times of Napoleon

If you’re familiar with GitHub, you’re probably aware that, these days, it’s used to store and manage many things beyond just software code. Now, thanks to the efforts of one developer, it also includes a piece of living history that’s had a global impact for two hundred years: namely, the French civil code.

Steeve Morin recently created a GitHub repository to store the collection of French laws first created under Napoleon (originally known as the Napoleonic Code), which subsequently influenced the legal systems in many other countries around the world. The repository not only contains the codes as they are currently constituted, but also the entire history of changes to the laws going back to the early 19th century, tracking modifications as commits to the various articles.

Morin notes in the file that the repository is the result of an afternoon of hacking. Describing how he did it in response to questions on Hacker News, Morin said he created the markdown files by writing a crawler in Go to scrape the code and its change history from Legifrance, a French government entity responsible for publishing legal texts online. While the French government also makes the civil code available as open data, Morin wrote that he chose instead to scrape Legifrance in order to get the full change history of the code.

Thanks to Morin’s efforts, France now joins the United States, Germany, Taiwan, and Japan as countries whose federal laws (some portion, at least) are now available on GitHub. Of course, to some people’s chagrin, the laws can’t be changed with a simple pull request, but repositories like these can still be pretty enlightening. Morin, for example, points to how his repository nicely lays out the changes France made to the code in May 2013 to legalize same-sex marriages.

As Morin wrote on GitHub (and as Michael Smith translated from French), “... the Civil Code is a part of the source code of France. And source code belongs in source control. Period.”

ITWorld DealPost: The best in tech deals and discounts.
Shop Tech Products at Amazon