GitHub offers a list of 33 licenses:

  • Academic Free License v3.0 afl-3.0
  • Apache license 2.0 apache-2.0
  • Artistic license 2.0 artistic-2.0
  • Boost Software License 1.0 bs1-1.0
  • BSD 2-clause "Simplified" license bsd-2-clause
  • BSD 3-clause "New" or "Revised" license bsd-3-clause
  • BSD 3-clause Clear license bsd-3-clause-clear
  • Creative Commons license family cc
  • Creative Commons Zero v1.0 Universal cc0-1.0
  • Creative Commons Attribution 4.0 cc-by-4.0
  • [...] Read more here: https://help.github.com/articles/licensing-a-repository/

I want to offer some customers a shirt (print object) from a selected GitHub repository snippet code. How does the copyright look for print objects? Does there exist a list in the web where licenses are listed with print information? Is it generally allowed to print code snippets of GitHub repositories?

EDIT #1:

To the first answer of amon: If I have understood right, I can use CC-BY-* licenses on print objects with attribution? Here an example: https://github.com/jamiebuilds/the-super-tiny-compiler/blob/master/LICENSE is licensed under CC-BY-4.0 - GitHub offers already a nice listing of permissions, limitations and conditions. Here the limitation is Trademark use/Patent use so I am not allowed to use this for a print object?

Another repository has the MIT License: https://github.com/ry/deno/blob/master/LICENSE it allows me trademark use.

So I have to go through each license available on GitHub (I only have to pay attention to those) and check the following (later I want to create a list of licenses which are allowed for print objects):

  • Permission for Commercial use
  • Permission for Distribution
  • Not having limitation of Trademark use
  • Not having limitation of Patent use

Is this the right way? To the attribution: I always attribute the author whatever license is used like github.com/ry/deno by Ryan Dahl (MIT)?

the snippet you take is so small and trivial that it is not covered by copyright - amon

I can not rely on this because the search of the code snippet is automated and the automation mechanism does not matter about the triviality.

  • 2
    Note that you can use many more licenses on GitHub than those 33. It’s just a list of licenses for which keywords are defined that can be used for GitHub’s search. Authors could also use any other license or no license at all. -- I don’t think that your question is actually about GitHub, but just about how to attribute source code on a t-shirt, no matter where this source code is hosted, no?
    – unor
    Jun 10, 2018 at 21:37
  • 1
    I only have to pay attention to this 33 GitHub licenses. But yes, you are right - I want to know if and how I am allowed to print source code on print objects? Jun 11, 2018 at 5:31

1 Answer 1


Neither printing T-shirts nor Github repositories are special for this question. You are asking whether you can reproduce copyrighted content. The answer is yes, if and only if one of the following cases applies:

  • the snippet you take is so small and trivial that it is not covered by copyright, or
  • your use is covered by some copyright exception (in Germany, a right to quote (§51 (2) UrhG), a highly transformative Freie Benutzung (§24 UrhG), or purely private/personal use (§53 UrhG) might be options), or
  • you obtain a license.

If the GH repository in question is offered under some public license, you already have a possible license. This license may impose various requirements, e.g. for attribution or for reproducing the license. This may be unsuitable for a T-shirt. The CC-BY-* licenses are particularly well suited for this kind of use because you can satisfy them easily with a short attribution. If you don't like the available public license, you can always ask the copyright holder for a separate license to a snippet – but they are not obliged to give you one.

Even if you have a copyright license to the snippet that gives you the necessary commercial rights (Verwertungsrechte), you are not free of obligations. In particular, you must still respect the moral rights (e.g. Urheberpersönlichkeitsrechte) and possibly credit the author (see §13 UrhG). A copyright license will also not give you rights to other kinds of IP, e.g. trademarks.

If you are the sole copyright holder of the GH repo, none of these considerations apply as you can freely license these T-shirts to your customers. You don't have to publish the repository under a T-shirt friendly license.

  • I edited the main question in relation to your answer because the comments section did not allow that character length. Jun 11, 2018 at 6:07
  • 1
    @MatthiasGünter I don't have time to discuss your edit in detail, but please consider: (1) The GH license summary is merely informational, and sometimes wrong. Please always read the actual license. (2) Since licenses on GH are not typically machine-readable, an automated solution seems infeasible. (3) Patents are probably irrelevant here. No common open source license lets you use trademarks. Most repos don't include trademarks, but it's difficult to know. (4) If you're trying to set up a T-shirt company in Germany, please involve an actual lawyer in order to reduce your risk of Abmahnungen.
    – amon
    Jun 13, 2018 at 14:32
  • The requirement to reproduce the license could potentially be solved by printing the license on a piece of paper included with the T-shirt.
    – user71659
    Oct 26, 2022 at 17:45

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.