Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions _data/meta.yml
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,11 @@
description: Additional information about the licenses
required: false


- name: related
description: Optional list of related license slugs (lowercase SPDX-derived filenames without .txt) shown in the sidebar
required: false

- name: redirect_from
description: Relative path(s) to redirect to the license from, to prevent breaking old URLs
required: false
18 changes: 18 additions & 0 deletions _includes/related-licenses.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
{% if page.related and page.related.size > 0 %}
<div class="related-licenses">
<h3 id="related-licenses">Related licenses</h3>
<ul>
{% for rel in page.related %}
{% assign rel_doc = site.licenses | where: "spdx-lcase", rel | first %}
{% if rel_doc == nil %}
{% assign rel_doc = site.licenses | where_exp: "item", "item.spdx-lcase == rel" | first %}
{% endif %}
{% if rel_doc %}
<li><a href="{{ rel_doc.url | relative_url }}">{{ rel_doc.title }}</a></li>
{% else %}
<li><a href="{{ '/licenses/' | append: rel | append: '/' | relative_url }}">{{ rel }}</a></li>
{% endif %}
{% endfor %}
</ul>
</div>
{% endif %}
2 changes: 2 additions & 0 deletions _includes/sidebar.html
Original file line number Diff line number Diff line change
Expand Up @@ -54,4 +54,6 @@ <h3>Who’s using this license?</h3>
</div>
{% endif %}

{% include related-licenses.html %}

</div> <!-- /sidebar -->
5 changes: 5 additions & 0 deletions _licenses/gpl-2.0.txt
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,11 @@ how: Create a text file (typically named LICENSE or LICENSE.txt) in the root of

note: The Free Software Foundation recommends taking the additional step of adding a boilerplate notice to the top of each file. The boilerplate can be found at the end of the license.

related:
- gpl-3.0
- agpl-3.0
- eupl-1.2

using:
Discourse: https://github.com/discourse/discourse/blob/master/LICENSE.txt
Jellyfin: https://github.com/jellyfin/jellyfin/blob/master/LICENSE
Expand Down
5 changes: 5 additions & 0 deletions _licenses/lgpl-2.1.txt
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,11 @@ how: Create a text file (typically named LICENSE or LICENSE.txt) in the root of

note: The Free Software Foundation recommends taking the additional step of adding a boilerplate notice to the top of each file. The boilerplate can be found at the end of the license.

related:
- lgpl-3.0
- mpl-2.0
- lgpl-2.0

using:

permissions:
Expand Down
5 changes: 5 additions & 0 deletions _licenses/mit.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,11 @@ description: A short and simple permissive license with conditions only requirin

how: Create a text file (typically named LICENSE or LICENSE.txt) in the root of your source code and copy the text of the license into the file. Replace [year] with the current year and [fullname] with the name (or names) of the copyright holders.

related:
- bsd-2-clause
- bsd-3-clause
- isc

using:
Babel: https://github.com/babel/babel/blob/master/LICENSE
.NET: https://github.com/dotnet/runtime/blob/main/LICENSE.TXT
Expand Down