Re:Ask HN: What do you think of reusing code you write betwe...
by Kaveren on Saturday November 24, 2018 @06:22PM
(#18524475)
I don't usually sign contracts, when I do it's mostly NDAs. Often times the code has inherent competitive value. When not under an NDA, I'm well within my legal rights to reuse all of my code at any time, I could put everything I write on GitHub tomorrow with a GPL license and there wouldn't be anything stopping me legally (I would never do this, of course). When under an NDA but not granting exclusive usage rights, I'm not sure how that plays out, but I haven't ran into that situation yet. I'm in a very, very niche position.
I do appreciate the word of advice, and will make sure to look out for it when I do need to sign contracts for long-term work.
Re:Ask HN: What do you think of reusing code you write betwe...
by cimmanom on Saturday November 24, 2018 @07:57PM
(#18524788)
In the US, most code written by an employee is considered a “work made for hire”, and the IP devolves automatically upon the employer. This is also usually written as a clause in most freelance/consulting contracts.
Re:Ask HN: What do you think of reusing code you write betwe...
by Kaveren on Saturday November 24, 2018 @09:19PM
(#18525065)
I looked into this a while ago. If I'm recalling correctly, code in particular is treated legally akin to a literary work, so it wouldn't be "work made for hire" by default. I might not be recalling correctly.
An employee also owns the copyright to his/her code (at least in most European countries), the company often just gains the exclusive right to use that code through the contract with the employee (or the law, in some countries). So whether or not it is you intellectual property does not matter that much, what is important is what's actually written in your freelancer contract. If you build a custom software system for a company I'd assume they will not simply let you sell "your" exact code to their competitor afterwards, at least if it's something that has some inherent competitive value (e.g. not simply an off-the-shelf solution like a CRM or website). Most companies make sure this can't happen even when working with a freelancer, so have a close look at your contract (if you have one). If there's no explicit contract it'll depend on the country you're in.