Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

*GPL -or-later and -only in sidebar instructions #563

Merged
merged 5 commits into from
Apr 24, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 2 additions & 2 deletions _includes/sidebar.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<div class="sidebar">

<a href="#" data-clipboard-target="#license-text" data-proofer-ignore="true" class="js-clipboard-button button">Copy license text to clipboard</a>

<div class="how-to-apply">
<h3>How to apply this license</h3>
<p>
Expand All @@ -14,7 +14,7 @@ <h3>How to apply this license</h3>
{% endif %}
{% assign xgpl = false %}
{% if page.spdx-id contains 'GPL' %}{% assign xgpl = true %}{% endif %}
<p class="note"><strong>Optional: </strong> Add <strong><code>{{ page.spdx-id }}</code>{% if xgpl %}+{% endif %}</strong>{% if xgpl %} (or <strong><code>{{ page.spdx-id }}</code></strong> to disallow future versions){% endif %} to your project's package description, if applicable (e.g., <a href="https://docs.npmjs.com/files/package.json#license">Node.js</a>, <a href="http://guides.rubygems.org/specification-reference/#license=">Ruby</a>, and <a href="https://doc.rust-lang.org/cargo/reference/manifest.html#package-metadata">Rust</a>). This will ensure the license is displayed in package directories.</p>
<p class="note"><strong>Optional: </strong> Add <strong><code>{{ page.spdx-id }}{% if xgpl %}-or-later{% endif %}</code></strong>{% if xgpl %} (or <strong><code>{{ page.spdx-id }}-only</code></strong> to disallow future versions){% endif %} to your project's package description, if applicable (e.g., <a href="https://docs.npmjs.com/files/package.json#license">Node.js</a>, <a href="http://guides.rubygems.org/specification-reference/#license=">Ruby</a>, and <a href="https://doc.rust-lang.org/cargo/reference/manifest.html#package-metadata">Rust</a>). This will ensure the license is displayed in package directories.</p>
</div>

{% if page.source %}
Expand Down
2 changes: 1 addition & 1 deletion _licenses/apache-2.0.txt
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ how: Create a text file (typically named LICENSE or LICENSE.txt) in the root of
note: The Apache Foundation recommends taking the additional step of adding a boilerplate notice to the header of each source file. You can find the notice at the very end of the license in the appendix.

using:
- Elasticsearch: https://github.com/elastic/elasticsearch/blob/master/LICENSE.txt
- Kubernetes: https://github.com/kubernetes/kubernetes/blob/master/LICENSE
- PDF.js: https://github.com/mozilla/pdf.js/blob/master/LICENSE
- Swift: https://github.com/apple/swift/blob/master/LICENSE.txt

permissions:
Expand Down
2 changes: 1 addition & 1 deletion spec/license_meta_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@
let(:detected) { Licensee::ProjectFiles::LicenseFile.new(content, 'LICENSE').license }

if example_url.start_with?('https://github.com/')
example_url.gsub!(%r{\Ahttps://github.com/([\w-]+/[\w-]+)/blob/([\w-]+/\S+)\z}, 'https://raw.githubusercontent.com/\1/\2')
example_url.gsub!(%r{\Ahttps://github.com/([\w-]+/[\w\.-]+)/blob/([\w-]+/\S+)\z}, 'https://raw.githubusercontent.com/\1/\2')
elsif example_url.start_with?('https://git.savannah.gnu.org/', 'https://git.gnome.org/')
example_url.gsub!(%r{/tree/}, '/plain/')
elsif example_url.start_with?('https://bitbucket.org/')
Expand Down