38
submitted 8 months ago by cyberwolfie@lemmy.ml to c/opensource@lemmy.ml

I have previously written a lot of code that is hosted on a public repo on GitHub, but it never had a license. It was written as part of my work while working for a non-commercial academic entity, and I would like to add a license before the link to the repo will be included in something that will be made public, potentially attracting one or two visitors.

This leaves me with a couple of questions:

  1. Can I just add a license after the fact and it will be valid for all prior work?
  2. Do I have to make sure the license is included in all branches of the repo, or does this not matter? There are for instance a couple of branches that are used to freeze the state of code at a certain time for reproducibility's sake (I know this could be solved in a better way, but that's how it is).
  3. I have myself reused some of the code in my current work for a commercial entity (internal analysis work, only distributed within the organization). Should this influence the type of license I choose? I am considering a GPL-license, but should I go with (what I believe to be) a more permissive license like MIT because of this?
you are viewing a single comment's thread
view the rest of the comments
[-] breadsmasher@lemmy.world 5 points 8 months ago* (last edited 8 months ago)

I am not a lawyer. I am a software dev. My understanding of this is solely based on projects going from open source to source available/more commercial licenses (Redis, Mongo, Elastic etc)

  1. The license change won’t apply retroactively - I am not sure theres a legal way to retroactively change licenses and terms? I am recalling back to the Unity runtime fee, which they wanted to apply retroactively, but there was a lot of noise/discussion on whether it was legal to even do this.

  2. Once you have main released version of the repo that contains the license you want to use going forward, any branches from that point should contain license by default? Since its just a file in the main branch.

  3. Since you are using it commercially, and want to change the license for future versions, you will absolutely want to discuss this with whatever entity is using it. You could choose a license they refuse to accept, and end up not being able to use any future releases. My employer will not use copy-left style licenses for example.

You also should keep in mind any other dependencies you have, and what licenses they have. It may influence what licenses you can use, or whether you can continue to use a certain dependency

[-] cyberwolfie@lemmy.ml 2 points 8 months ago

Thanks for your answer.

  1. The license change won’t apply retroactively - I am not sure theres a legal way to retroactively change licenses and terms? I am recalling back to the Unity runtime fee, which they wanted to apply retroactively, but there was a lot of noise/discussion on whether it was legal to even do this.

OK, in that case it may not even make much sense to add a license. There will be no added code to this repo in the future, so there will nothing the new license would apply to.

  1. Once you have main released version of the repo that contains the license you want to use going forward, any branches from that point should contain license by default? Since its just a file in the main branch.

Yes, you kind of answered this in question 1. Since it is not retroactively applied, it won't apply to the stale branches that only exist as snapshots of the code.

  1. Since you are using it commercially, and want to change the license for future versions, you will absolutely want to discuss this with whatever entity is using it. You could choose a license they refuse to accept, and end up not being able to use any future releases. My employer will not use copy-left style licenses for example.

Good point. This is not included in any software that is distributed, it is only a smaller part of an internal codebase used for data analysis. Does that not change things? But to be on the safe side, it would probably make sense to make it as permissive as possible to avoid any issues here. But then again, if it is not applied retroactively then nothing of the code used will be subject to any license. But good thing to remember for the future.

[-] nix@midwest.social 2 points 8 months ago* (last edited 8 months ago)

Also not a lawyer, but you can also grant exceptions to the license (if you're the sole owner of the code), so you can license code one way and let a certain org use it another way.

Which is essentially already what's happening. The default "license" of something is that you have full ownership and no rights are given to anyone else. You've essentially give your company an exception to use it for that project.

load more comments (4 replies)
load more comments (5 replies)
this post was submitted on 01 Apr 2024
38 points (93.2% liked)

Open Source

31358 readers
17 users here now

All about open source! Feel free to ask questions, and share news, and interesting stuff!

Useful Links

Rules

Related Communities

Community icon from opensource.org, but we are not affiliated with them.

founded 5 years ago
MODERATORS