www.eamoncaddigan.net

Content and configuration for https://www.eamoncaddigan.net
git clone https://git.eamoncaddigan.net/www.eamoncaddigan.net.git
Log | Files | Refs | Submodules | README

index.md (3943B)


      1 ---
      2 title: "Just use the GPL"
      3 description: "The GNU General Public License is the best license to attach to your small open-source projects."
      4 date: 2022-10-18T20:46:57-07:00
      5 draft: False
      6 categories:
      7 - Programming
      8 - Data Science
      9 ---
     10 
     11 **Tl;dr:** if you choose to publish some code that you've written by
     12 yourself, and you want attach an "open source" license to that code, you'll
     13 probably be happiest if you choose the
     14 [GPLv3](https://www.gnu.org/licenses/gpl-3.0.en.html).
     15 
     16 There are many of reasons to publish your code (or data analysis) with an
     17 open source license (maybe it's something you've made [just for
     18 fun](https://justforfunnoreally.dev/)), and there are nearly as many
     19 licenses to choose from. Twenty years ago, when the free and open source
     20 software (FOSS) phenomenon was starting to penetrate the public conscious,
     21 the GNU GPL was practically synonymous with "open source". But in
     22 contemporary practice, more permissive FOSS licenses are more popular (due
     23 in part, I suspect, to the [encouragement of organizations such as
     24 Microsoft-owned
     25 GitHub](https://tom.preston-werner.com/2011/11/22/open-source-everything.html)).
     26 
     27 The GPL is a "copyleft" license, designed to use copyright law to spread
     28 open source across the computing ecosystem; people who mix code with a GPL
     29 license with code of their own must  release the ensuing product under the
     30 same license. The [MIT license](https://mit-license.org/), which was [the
     31 most popular license for GitHub projects as of
     32 2015](https://github.blog/2015-03-09-open-source-license-usage-on-github-com/),
     33 is an example of a "permissive" license; it mainly protects the original
     34 code author from claims of liability, and allows people to use it however
     35 they wish. You can incorporate MIT-licensed code into a closed-source
     36 project without asking for permission, or even informing the original author
     37 of the code.
     38 
     39 I'm not here to evangelize FOSS, or argue that any license (or class of
     40 license) is better than any other _in general_. The most successful and
     41 important FOSS projects are community efforts, and the choice of license
     42 should be made by the community. But while it might be true that most FOSS
     43 _code_ is written as part of such projects, I would guess that most FOSS
     44 _projects_ are small one-off efforts undertaken by individuals who happen to
     45 have chosen to publish their code in a manner that allows its reuse. If
     46 you're thinking of doing this, I recommend that you license your code under
     47 the GPL.
     48 
     49 The solo-programmer (or data scientist) releasing a small project of their
     50 own is best served by the GPL because it offers a compromise between
     51 maintaining full control of their code (as does traditional copyright) and
     52 supporting other FOSS projects. You might argue, "I'm not an open-source
     53 zealot, I don't mind some projects being closed source!" That's not a
     54 problem; if you release your own code under the GPL, you can still offer it
     55 under different licenses on a case-by-case basis. If somebody contacts you
     56 asking to use your code in their closed-source project—and you should
     57 encourage people to do so—you get to decide whether their product, company,
     58 and business model are things that you want to support. The only people who
     59 are allowed to use your code without checking in with you are other
     60 open-source developers releasing FOSS of their own. As a programmer
     61 considering open-sourcing your project, this is presumably something that
     62 you support.
     63 
     64 I'm actually not a fan of "intellectual property" restrictions; I believe
     65 that copyright and patents do more harm than good for science, the arts, and
     66 even commerce. However, as long as we live in a world with copyright laws, I
     67 believe that we should use them to ensure that our values can flourish. I
     68 haven't bothered changing the license on all of my (small and simple) public
     69 projects—I'm not even sure it's worth the effort. However, moving forward,
     70 almost everything I post will be available under the GPL.