1
0
mirror of https://github.com/github/choosealicense.com synced 2024-12-22 21:00:10 +01:00

Merge remote-tracking branch 'github/gh-pages' into osl-3.0

Conflicts:
	_config.yml
This commit is contained in:
Derek Jones 2015-08-06 10:22:19 -07:00
commit c30ff9e20a
50 changed files with 413 additions and 477 deletions

2
.gitignore vendored
View File

@ -8,3 +8,5 @@ assets/vendor/zeroclipboard/test
assets/vendor/selectivizr/tests assets/vendor/selectivizr/tests
assets/vendor/qtip2/basic assets/vendor/qtip2/basic
/vendor /vendor
Gemfile.lock
/.sass-cache

View File

@ -14,3 +14,10 @@ branches:
notifications: notifications:
email: false email: false
env:
global:
- NOKOGIRI_USE_SYSTEM_LIBRARIES=true
sudo: false
cache: bundler

View File

@ -24,12 +24,12 @@ The easiest way to make a change is to simply edit a file from your browser.
When you click the edit button, it will fork the repository under your account. When you click the edit button, it will fork the repository under your account.
Note what issue/issues your patch fixes in the commit message. Note what issue/issues your patch fixes in the commit message.
For example, to [change this file](https://github.com/github/choosealicense.com/blob/master/CONTRIBUTING.md), For example, to [change this file](/CONTRIBUTING.md),
find it in the GitHub repository. Then click the `Edit` button. Make your find it in the GitHub repository. Then click the `Edit` button. Make your
changes, type in a commit message, and click the `Propose File Change` button. changes, type in a commit message, and click the `Propose File Change` button.
Thats it! Thats it!
For more advanced changes, check out [the bootstrap instructions](https://github.com/github/choosealicense.com#run-it-on-your-machine) in the [project's readme](https://github.com/github/choosealicense.com/blob/master/README.md). For more advanced changes, check out [the bootstrap instructions](https://github.com/github/choosealicense.com#run-it-on-your-machine) in the [project's readme](/README.md).
## Testing ## Testing

View File

@ -6,4 +6,5 @@ gem "github-pages"
group :test do group :test do
gem "html-proofer" gem "html-proofer"
gem "rake" gem "rake"
gem "rspec"
end end

View File

@ -1,110 +0,0 @@
GEM
remote: https://rubygems.org/
specs:
RedCloth (4.2.9)
activesupport (4.1.1)
i18n (~> 0.6, >= 0.6.9)
json (~> 1.7, >= 1.7.7)
minitest (~> 5.1)
thread_safe (~> 0.1)
tzinfo (~> 1.1)
blankslate (2.1.2.4)
classifier (1.3.4)
fast-stemmer (>= 1.0.0)
colorator (0.1)
colored (1.2)
commander (4.1.6)
highline (~> 1.6.11)
ethon (0.7.0)
ffi (>= 1.3.0)
fast-stemmer (1.0.2)
ffi (1.9.3)
gemoji (1.5.0)
github-pages (18)
RedCloth (= 4.2.9)
jekyll (= 1.5.1)
jekyll-mentions (= 0.0.6)
jekyll-redirect-from (= 0.3.1)
jekyll-sitemap (= 0.2.0)
jemoji (= 0.1.0)
kramdown (= 1.3.1)
liquid (= 2.5.5)
maruku (= 0.7.0)
rdiscount (= 2.1.7)
redcarpet (= 2.3.0)
highline (1.6.21)
html-pipeline (1.5.0)
activesupport (>= 2)
nokogiri (~> 1.4)
html-proofer (0.6.7)
colored (~> 1.2)
mercenary (~> 0.3.2)
nokogiri (~> 1.6.0)
typhoeus (~> 0.6.7)
i18n (0.6.9)
jekyll (1.5.1)
classifier (~> 1.3)
colorator (~> 0.1)
commander (~> 4.1.3)
liquid (~> 2.5.5)
listen (~> 1.3)
maruku (= 0.7.0)
pygments.rb (~> 0.5.0)
redcarpet (~> 2.3.0)
safe_yaml (~> 1.0)
toml (~> 0.1.0)
jekyll-mentions (0.0.6)
html-pipeline (~> 1.5.0)
jekyll (~> 1.4)
jekyll-redirect-from (0.3.1)
jekyll (~> 1.4)
jekyll-sitemap (0.2.0)
jekyll (~> 1.4)
jemoji (0.1.0)
gemoji (~> 1.5.0)
html-pipeline (~> 1.5.0)
jekyll (~> 1.4)
json (1.8.1)
kramdown (1.3.1)
liquid (2.5.5)
listen (1.3.1)
rb-fsevent (>= 0.9.3)
rb-inotify (>= 0.9)
rb-kqueue (>= 0.2)
maruku (0.7.0)
mercenary (0.3.3)
mini_portile (0.5.3)
minitest (5.3.3)
nokogiri (1.6.1)
mini_portile (~> 0.5.0)
parslet (1.5.0)
blankslate (~> 2.0)
posix-spawn (0.3.8)
pygments.rb (0.5.4)
posix-spawn (~> 0.3.6)
yajl-ruby (~> 1.1.0)
rake (10.3.1)
rb-fsevent (0.9.4)
rb-inotify (0.9.4)
ffi (>= 0.5.0)
rb-kqueue (0.2.2)
ffi (>= 0.5.0)
rdiscount (2.1.7)
redcarpet (2.3.0)
safe_yaml (1.0.3)
thread_safe (0.3.3)
toml (0.1.1)
parslet (~> 1.5.0)
typhoeus (0.6.8)
ethon (>= 0.7.0)
tzinfo (1.1.0)
thread_safe (~> 0.1)
yajl-ruby (1.1.0)
PLATFORMS
ruby
DEPENDENCIES
github-pages
html-proofer
rake

View File

@ -1,4 +1,4 @@
Copyright (c) 2014 GitHub, Inc. Copyright (c) 2013 GitHub, Inc.
Permission is hereby granted, free of charge, to any person obtaining a copy Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal of this software and associated documentation files (the "Software"), to deal

View File

@ -8,12 +8,12 @@ A lot of repositories on GitHub.com don't have a license. GitHub provides
a license chooser, but if you don't know anything about licenses, how are you a license chooser, but if you don't know anything about licenses, how are you
supposed to make an informed decision? supposed to make an informed decision?
ChooseALicense.com is designed to help people make an informed decision about [ChooseALicense.com](http://www.choosealicense.com "Choose A Licence website") is designed to help people make an informed decision about
licenses. licenses.
# Immediate Goals # Immediate Goals
* Politics Free - Let's just not get into it. * Non-partisan. Our goal is to help you find a license that meets *your* goals.
* Well designed, but that goes without saying. * Well designed, but that goes without saying.
* The homepage should have just enough to help 99% of folks make a decision. * The homepage should have just enough to help 99% of folks make a decision.
* For the 1%, the site will contain a list of licenses common to specific * For the 1%, the site will contain a list of licenses common to specific
@ -65,11 +65,10 @@ notices. The available variables are:
# Rules # Rules
Rules (the license's properties) are stored as a bulleted list within the Rules (the license's properties) are stored as a bulleted list within the
licenses YAML front matter. A full list of rules can be found in the licenses YAML front matter. A full list of rules can be found in `_data/rules.yml`.
repository's `_config.yml` file. Each rule has a name e.g., Each rule has a name e.g., `include-copyright`, a human-readable label, e.g.,
`include-copyright`, a human-readable label, e.g., `Copyright inclusion`, `Copyright inclusion`, and a description `Include the original copyright with the code`.
and a description `Include the original copyright with the code`. To add a new rule, simply add it to `_data/rules.yml` and reference it in the
To add a new rule, simply add it to `config.yml` and reference it in the
appropriate license. appropriate license.
# License # License

View File

@ -1,7 +1,14 @@
require "html/proofer" require "html/proofer"
require 'rspec/core/rake_task'
desc "Run specs"
RSpec::Core::RakeTask.new do |t|
t.pattern = 'spec/**/*_spec.rb'
t.rspec_opts = ["--order", "rand", "--color"]
end
task :test do task :test do
sh "bundle exec jekyll build --trace" sh "bundle exec jekyll build --trace"
# ignore href="#" for the "Copy to clipboard" button HTML::Proofer.new("./_site", :check_html => true).run
HTML::Proofer.new("./_site").run Rake::Task["spec"].invoke
end end

View File

@ -4,77 +4,41 @@ relative_permalinks: false
markdown: kramdown markdown: kramdown
url: "http://choosealicense.com" url: "http://choosealicense.com"
rules: collections:
licenses:
output: true
permalink: /licenses/:path/
required: defaults:
- description: Include a copy of the license and copyright notice with the code. -
label: License and copyright notice scope:
tag: include-copyright path: ""
- description: Indicate significant changes made to the code. type: "licenses"
label: State Changes values:
tag: document-changes layout: license
- description: Source code must be made available when distributing the software. In the case of LGPL and OSL 3.0, the source for the library (and not the entire program) must be made available. featured: false
label: Disclose Source "hide-from-license-list": false
tag: disclose-source
- description: The library may be used within a non-open-source application.
label: Library usage
tag: library-usage
- description: You must change the name of the software if you modify it.
label: Rename
tag: rename
permitted:
- description: This software and derivatives may be used for commercial purposes.
label: Commercial Use
tag: commercial-use
- description: This software may be modified.
label: Modification
tag: modifications
- description: You may distribute this software.
label: Distribution
tag: distribution
- description: You may grant a sublicense to modify and distribute this software to third parties not included in the license.
label: Sublicensing
tag: sublicense
- description: You may use and modify the software without distributing it.
label: Private Use
tag: private-use
- description: This license provides an express grant of patent rights from the contributor to the recipient.
label: Patent Grant
tag: patent-grant
forbidden:
- description: While this may be implicitly true of all licenses, this license explicitly states that you may NOT use the names, logos, or trademarks of contributors.
label: Use Trademark
tag: trademark-use
- description: Software is provided without warranty and the software author/license owner cannot be held liable for damages.
label: Hold Liable
tag: no-liability
- description: You may not grant a sublicense to modify and distribute this software to third parties not included in the license.
label: Sublicensing
tag: no-sublicense
- description: This software may not be modified.
label: Modification
tag: modifications
- description: You may not distribute this software.
label: Distribution
tag: distribution
- description: You may not grant a sublicense to modify and distribute this software to third parties not included in the license.
label: Sublicensing
tag: sublicense
exclude: exclude:
- app.coffee - app.coffee
- CNAME - CNAME
- CONTRIBUTING.md - CONTRIBUTING.md
- Gemfile - Gemfile
- Gemfile.lock - Gemfile.lock
- LICENSE.md - LICENSE.md
- licenses.json - Rakefile
- Rakefile - README.md
- README.md - script
- script - vendor/bundle
- bundle - test
- tests
- assets/vendor/selectivizr/tests
- assets/vendor/zeroclipboard/test
gems: gems:
- jekyll-sitemap - jekyll-sitemap
- jekyll-redirect-from
sass:
sass_dir: _sass
style: :compressed

59
_data/rules.yml Normal file
View File

@ -0,0 +1,59 @@
required:
- description: Include a copy of the license and copyright notice with the code.
label: License and copyright notice
tag: include-copyright
- description: Indicate significant changes made to the code.
label: State Changes
tag: document-changes
- description: Source code must be made available when distributing the software. In the case of LGPL and OSL 3.0, the source for the library (and not the entire program) must be made available.
label: Disclose Source
tag: disclose-source
- description: Users who interact with the software via network are given the right to receive a copy of the corresponding source code.
label: Network Use is Distribution
tag: network-use-disclose
- description: The library may be used within a non-open-source application.
label: Library usage
tag: library-usage
- description: You must change the name of the software if you modify it.
label: Rename
tag: rename
permitted:
- description: This software and derivatives may be used for commercial purposes.
label: Commercial Use
tag: commercial-use
- description: This software may be modified.
label: Modification
tag: modifications
- description: You may distribute this software.
label: Distribution
tag: distribution
- description: You may grant a sublicense to modify and distribute this software to third parties not included in the license.
label: Sublicensing
tag: sublicense
- description: You may use and modify the software without distributing it.
label: Private Use
tag: private-use
- description: This license provides an express grant of patent rights from the contributor to the recipient.
label: Patent Grant
tag: patent-grant
forbidden:
- description: While this may be implicitly true of all licenses, this license explicitly states that you may NOT use the names, logos, or trademarks of contributors.
label: Use Trademark
tag: trademark-use
- description: Software is provided without warranty and the software author/license owner cannot be held liable for damages.
label: Hold Liable
tag: no-liability
- description: You may not grant a sublicense to modify and distribute this software to third parties not included in the license.
label: Sublicensing
tag: no-sublicense
- description: This software may not be modified.
label: Modification
tag: modifications
- description: You may not distribute this software.
label: Distribution
tag: distribution
- description: You may not grant a sublicense to modify and distribute this software to third parties not included in the license.
label: Sublicensing
tag: sublicense

File diff suppressed because one or more lines are too long

View File

@ -1 +0,0 @@
/*! normalize.css v3.0.0 | MIT License | git.io/normalize */html{font-family:sans-serif;-ms-text-size-adjust:100%;-webkit-text-size-adjust:100%}body{margin:0}article,aside,details,figcaption,figure,footer,header,hgroup,main,nav,section,summary{display:block}audio,canvas,progress,video{display:inline-block;vertical-align:baseline}audio:not([controls]){display:none;height:0}[hidden],template{display:none}a{background:0 0}a:active,a:hover{outline:0}abbr[title]{border-bottom:1px dotted}b,strong{font-weight:700}dfn{font-style:italic}h1{font-size:2em;margin:.67em 0}mark{background:#ff0;color:#000}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sup{top:-.5em}sub{bottom:-.25em}img{border:0}svg:not(:root){overflow:hidden}figure{margin:1em 40px}hr{-moz-box-sizing:content-box;box-sizing:content-box;height:0}pre{overflow:auto}code,kbd,pre,samp{font-family:monospace,monospace;font-size:1em}button,input,optgroup,select,textarea{color:inherit;font:inherit;margin:0}button{overflow:visible}button,select{text-transform:none}button,html input[type=button],input[type=reset],input[type=submit]{-webkit-appearance:button;cursor:pointer}button[disabled],html input[disabled]{cursor:default}button::-moz-focus-inner,input::-moz-focus-inner{border:0;padding:0}input{line-height:normal}input[type=checkbox],input[type=radio]{box-sizing:border-box;padding:0}input[type=number]::-webkit-inner-spin-button,input[type=number]::-webkit-outer-spin-button{height:auto}input[type=search]{-webkit-appearance:textfield;-moz-box-sizing:content-box;-webkit-box-sizing:content-box;box-sizing:content-box}input[type=search]::-webkit-search-cancel-button,input[type=search]::-webkit-search-decoration{-webkit-appearance:none}fieldset{border:1px solid silver;margin:0 2px;padding:.35em .625em .75em}legend{border:0;padding:0}textarea{overflow:auto}optgroup{font-weight:700}table{border-collapse:collapse;border-spacing:0}td,th{padding:0}

View File

@ -15,18 +15,21 @@
</div> <!-- /container --> </div> <!-- /container -->
{% if page.layout == "license" or page.class == "license-types" %} {% if page.collection == "licenses" or page.class == "license-types" %}
<script src="/assets/vendor/jquery/jquery.min.js"></script> <script src="/assets/vendor/jquery/jquery.min.js"></script>
<script src="/assets/vendor/qtip2/jquery.qtip.min.js"></script> <script src="/assets/vendor/qtip2/jquery.qtip.min.js"></script>
<script src="/assets/vendor/zeroclipboard/ZeroClipboard.min.js"></script> <script src="/assets/vendor/zeroclipboard/ZeroClipboard.min.js"></script>
<script src="/assets/js/javascript.js"></script> <script>
window.annotations = {{ site.data.rules | jsonify }};
</script>
<script src="/assets/js/app.js"></script>
{% endif %} {% endif %}
<script> <script>
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){ !function(L,I,C,e,N,S,E){L.GoogleAnalyticsObject=N,L[N]=L[N]||function(){
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o), (L[N].q=L[N].q||[]).push(arguments)},L[N].l=+new Date,S=I.createElement(C),
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m) E=I.getElementsByTagName(C)[0],S.src=e,E.parentNode.insertBefore(S,E)
})(window,document,'script','//www.google-analytics.com/analytics.js','ga'); }(window,document,"script","//www.google-analytics.com/analytics.js","ga");
ga('create', 'UA-3769691-24', 'choosealicense.com'); ga('create', 'UA-3769691-24', 'choosealicense.com');
ga('send', 'pageview'); ga('send', 'pageview');

View File

@ -6,9 +6,7 @@
<title>{% if page.title %}{{ page.title | markdownify | strip_html | strip_newlines }} - {% endif %}{{ site.title}}</title> <title>{% if page.title %}{{ page.title | markdownify | strip_html | strip_newlines }} - {% endif %}{{ site.title}}</title>
{% if page.description %}<meta name="description" content="{{ page.description | strip_html | strip_newlines }}">{% endif %} {% if page.description %}<meta name="description" content="{{ page.description | strip_html | strip_newlines }}">{% endif %}
<link rel="stylesheet" href="//fonts.googleapis.com/css?family=Chivo:900"> <link rel="stylesheet" href="//fonts.googleapis.com/css?family=Chivo:900">
<link rel="stylesheet" href="/assets/vendor/normalize-css/normalize.css"> <link rel="stylesheet" href="/assets/css/application.css?v={{ site.github.build_revision }}">
<link rel="stylesheet" href="/assets/vendor/qtip2/jquery.qtip.min.css">
<link rel="stylesheet" href="/assets/css/application.css">
<link rel="shortcut icon" href="/favicon.ico" type="image/x-icon"> <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon">
<!--[if lt IE 9]> <!--[if lt IE 9]>
<script src="/assets/vendor/html5shiv/dist/html5shiv.js"></script> <script src="/assets/vendor/html5shiv/dist/html5shiv.js"></script>

View File

@ -1,9 +0,0 @@
var annotations = {
{% for type_hash in site.rules %}
"{{ type_hash[0] }}": {
{% for rule_hash in type_hash[1] %}
"{{ rule_hash.tag }}" : "{{ rule_hash.description }}"{% if forloop.rindex0 > 0 %},{% endif %}
{% endfor %}
}{% if forloop.rindex0 > 0 %},{% endif %}
{% endfor %}
};

View File

@ -1,132 +0,0 @@
// Generated by CoffeeScript 1.7.1
(function() {
var Choosealicense;
Choosealicense = (function() {
Choosealicense.prototype.flashAvailable = function() {
if (typeof ActiveXObject !== "undefined" && ActiveXObject !== null) {
return !!(new ActiveXObject("ShockwaveFlash.ShockwaveFlash"));
} else {
return !!navigator.mimeTypes["application/x-shockwave-flash"];
}
};
Choosealicense.prototype.selectText = function(element) {
var range, selection;
if (document.body.createTextRange) {
range = document.body.createTextRange();
range.moveToElementText(element);
return range.select();
} else if (window.getSelection) {
selection = window.getSelection();
range = document.createRange();
range.selectNodeContents(element);
selection.removeAllRanges();
return selection.addRange(range);
}
};
Choosealicense.prototype.qtip_position = {
my: "top center",
at: "bottom center"
};
Choosealicense.prototype.categories = {
required: "Required",
permitted: "Permitted",
forbidden: "Forbidden"
};
function Choosealicense() {
this.initTooltips();
this.initClipboard();
this.initLicenseVariationNav();
}
Choosealicense.prototype.initTooltips = function() {
var category, label, rules, text, _ref;
for (category in annotations) {
rules = annotations[category];
for (label in rules) {
text = rules[label];
$(".license-rules ul.license-" + category + " li." + label).attr("title", text);
}
}
_ref = this.categories;
for (category in _ref) {
label = _ref[category];
$(".license-" + category + " li").qtip({
content: {
text: false,
title: {
text: label
}
},
position: this.qtip_position,
style: {
classes: "qtip-shadow qtip-" + category
}
});
}
return false;
};
Choosealicense.prototype.initZeroClipboard = function() {
var clip;
$(".js-clipboard-button").data("clipboard-prompt", $(".js-clipboard-button").text());
clip = new ZeroClipboard($(".js-clipboard-button"), {
moviePath: "/assets/vendor/zeroclipboard/ZeroClipboard.swf"
});
clip.on("mouseout", this.clipboardMouseout);
clip.on("complete", this.clipboardComplete);
return clip;
};
Choosealicense.prototype.initAlternativeClipboard = function() {
return $(".js-clipboard-button").click((function(_this) {
return function(e) {
var target;
target = "#" + $(e.target).data("clipboard-target");
return _this.selectText($(target)[0]);
};
})(this));
};
Choosealicense.prototype.initClipboard = function() {
if ((typeof ZeroClipboard !== "undefined" && ZeroClipboard !== null) && this.flashAvailable()) {
return this.initZeroClipboard();
} else {
return this.initAlternativeClipboard();
}
};
Choosealicense.prototype.clipboardMouseout = function(client, args) {
return this.innerText = $(this).data("clipboard-prompt");
};
Choosealicense.prototype.clipboardComplete = function(client, args) {
return this.innerText = "Copied!";
};
Choosealicense.prototype.initLicenseVariationNav = function() {
return $(".js-nav-pills a").click(function(e) {
var nav, selectedTab;
selectedTab = $(this).data("selected-tab");
nav = $(this).closest(".js-nav-pills");
nav.find("li").removeClass("active");
nav.closest(".js-license-variations").siblings(".js-variation-tab").removeClass("active");
$(this).parent("li").addClass("active");
$("." + selectedTab).addClass("active");
return e.preventDefault();
});
};
return Choosealicense;
})();
$(function() {
return new Choosealicense();
});
}).call(this);

View File

@ -1,26 +1,36 @@
<div class="license-family clearfix"> <div class="license-family clearfix">
<div class="license-family-heading"> <div class="license-family-heading">
<h3 class="license-family-name"><a href="{{ page.permalink }}">{% if page.category %}{{ page.category }}{% else %}{{ page.title }}{% endif %}</a></h3> <h3 class="license-family-name">
<a href="{{ license.permalink }}">
{% if license.category %}{{ license.category }}{% else %}{{ license.title }}{% endif %}
</a>
</h3>
<p class="license-family-description">{{ page.description }}</p> <p class="license-family-description">{{ license.description }}</p>
</div> </div>
<div class="license-details"> <div class="license-details">
<div class="license-variations js-license-variations"> <div class="license-variations js-license-variations">
<!-- always show this div, even w/o variations, for proper spacing --> <!-- always show this div, even w/o variations, for proper spacing -->
{% if page.tab-slug %} {% if license.tab-slug %}
<ul class="nav-pills js-nav-pills"> <ul class="nav-pills js-nav-pills">
{% for variation in site.pages %} {% for variation in site.licenses %}
{% if variation.category and variation.category == page.category %} {% if variation.category and variation.category == license.category %}
<li{% if page.tab-slug == variation.tab-slug %} class="active"{% endif %}><a href="#{{ variation.tab-slug }}" data-selected-tab="variation-{{ variation.tab-slug }}">{{ variation.title }}</a></li> <li{% if license.tab-slug == variation.tab-slug %} class="active"{% endif %}><a href="#{{ variation.tab-slug }}" data-selected-tab="variation-{{ variation.tab-slug }}">
{% if variation.nickname != nil %}
{{ variation.nickname }}
{% else %}
{{ variation.title }}
{% endif %}
</a></li>
{% endif %} {% endif %}
{% endfor %} {% endfor %}
</ul> </ul>
{% endif %} {% endif %}
</div> </div>
{% for variation in site.pages %} {% for variation in site.licenses %}
{% if variation.category and variation.category == page.category %} {% if variation.category and variation.category == license.category %}
<div {% if variation.tab-slug %}id="{{ variation.tab-slug }}" {% endif %}class="variation-tab {% if variation.tab-slug %}variation-{{ variation.tab-slug }}{% endif %} js-variation-tab{% if page.tab-slug == variation.tab-slug %} active{% endif %}"> <div {% if variation.tab-slug %}id="{{ variation.tab-slug }}" {% endif %}class="variation-tab {% if variation.tab-slug %}variation-{{ variation.tab-slug }}{% endif %} js-variation-tab{% if license.tab-slug == variation.tab-slug %} active{% endif %}">
<table class="license-rules"> <table class="license-rules">
<tr> <tr>
{% assign types = "required|permitted|forbidden" | split: "|" %} {% assign types = "required|permitted|forbidden" | split: "|" %}
@ -32,7 +42,7 @@
{% for type in types %} {% for type in types %}
<td> <td>
<ul class="license-{{ type }}"> <ul class="license-{{ type }}">
{% assign rules = site.rules[type] | sort: "label" %} {% assign rules = site.data.rules[type] | sort: "label" %}
{% for rule_obj in rules %} {% for rule_obj in rules %}
{% assign req = rule_obj.tag %} {% assign req = rule_obj.tag %}
{% if variation[type] contains req %} {% if variation[type] contains req %}

View File

@ -27,7 +27,7 @@
{% for type in types %} {% for type in types %}
<h3>{{ type | capitalize }}</h3> <h3>{{ type | capitalize }}</h3>
<ul class="license-{{ type }}"> <ul class="license-{{ type }}">
{% assign rules = site.rules[type] | sort: "label" %} {% assign rules = site.data.rules[type] | sort: "label" %}
{% for rule_obj in rules %} {% for rule_obj in rules %}
{% assign req = rule_obj.tag %} {% assign req = rule_obj.tag %}
{% if page[type] contains req %} {% if page[type] contains req %}

View File

@ -1,11 +1,15 @@
--- ---
title: Affero GPL title: GNU Affero General Public License v3.0
nickname: GNU Affero GPL v3.0
category: GPL category: GPL
tab-slug: agpl tab-slug: agpl-v3
hide-from-license-list: true hide-from-license-list: true
layout: license layout: license
permalink: /licenses/agpl/ permalink: /licenses/agpl-3.0/
source: http://www.gnu.org/licenses/agpl-3.0.txt source: http://www.gnu.org/licenses/agpl-3.0.txt
redirect_from: /licenses/agpl/
description: "The GPL family of licenses is the most widely used free software license and has a strong copyleft requirement. When distributing derived works, the source code of the work must be made available under the same license. The AGPL family of licenses is distinguished from GPLv2 and GPLv3 in that hosted services using the code are considered distribution and trigger the copyleft requirements."
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. 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.
@ -15,11 +19,13 @@ required:
- include-copyright - include-copyright
- document-changes - document-changes
- disclose-source - disclose-source
- network-use-disclose
permitted: permitted:
- commercial-use - commercial-use
- modifications - modifications
- distribution - distribution
- patent-grant
- private-use - private-use
forbidden: forbidden:

View File

@ -1,8 +1,9 @@
--- ---
title: Apache v2 License title: Apache License 2.0
category: Apache category: Apache
layout: license layout: license
permalink: /licenses/apache/ permalink: /licenses/apache-2.0/
redirect_from: /licenses/apache/
featured: true featured: true

View File

@ -2,8 +2,9 @@
layout: license layout: license
title: Artistic License 2.0 title: Artistic License 2.0
category: Artistic category: Artistic
permalink: /licenses/artistic/ redirect_from: /licenses/artistic/
source: http://www.perlfoundation.org/attachment/legal/artistic-2_0.txt source: http://www.perlfoundation.org/attachment/legal/artistic-2_0.txt
permalink: /licenses/artistic-2.0/
description: Heavily favored by the Perl community, the Artistic license requires that modified versions of the software do not prevent users from running the standard version. description: Heavily favored by the Perl community, the Artistic license requires that modified versions of the software do not prevent users from running the standard version.

View File

@ -1,10 +1,12 @@
--- ---
layout: license layout: license
title: BSD 2-Clause license title: BSD 2-clause "Simplified" License
nickname: Simplified BSD
category: BSD category: BSD
tab-slug: bsd tab-slug: bsd
hide-from-license-list: false hide-from-license-list: true
permalink: /licenses/bsd/ redirect_from: /licenses/bsd/
permalink: /licenses/bsd-2-clause/
description: A permissive license that comes in two variants, the <a href="/licenses/bsd">BSD 2-Clause</a> and <a href="/licenses/bsd-3-clause">BSD 3-Clause</a>. Both have very minute differences to the MIT license. description: A permissive license that comes in two variants, the <a href="/licenses/bsd">BSD 2-Clause</a> and <a href="/licenses/bsd-3-clause">BSD 3-Clause</a>. Both have very minute differences to the MIT license.

View File

@ -1,12 +1,15 @@
--- ---
layout: license layout: license
title: BSD (3-Clause) License title: BSD 3-clause "New" or "Revised" License
nickname: New BSD
category: BSD category: BSD
tab-slug: bsd-3 tab-slug: bsd-3
hide-from-license-list: true hide-from-license-list: true
permalink: /licenses/bsd-3-clause/ permalink: /licenses/bsd-3-clause/
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. Replace {organization} with the organization, if any, that sponsors this work. description: A permissive license that comes in two variants, the <a href="/licenses/bsd">BSD 2-Clause</a> and <a href="/licenses/bsd-3-clause">BSD 3-Clause</a>. Both have very minute differences to the MIT license. The three clause variant prohibits others from using the name of the project or its contributors to promote derivative works without written consent.
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. Replace [project] with the project organization, if any, that sponsors this work.
source: http://opensource.org/licenses/BSD-3-Clause source: http://opensource.org/licenses/BSD-3-Clause
@ -39,7 +42,7 @@ modification, are permitted provided that the following conditions are met:
this list of conditions and the following disclaimer in the documentation this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution. and/or other materials provided with the distribution.
* Neither the name of the {organization} nor the names of its * Neither the name of [project] nor the names of its
contributors may be used to endorse or promote products derived from contributors may be used to endorse or promote products derived from
this software without specific prior written permission. this software without specific prior written permission.

View File

@ -1,6 +1,7 @@
--- ---
layout: license layout: license
title: CC0 1.0 Universal title: Creative Commons Zero v1.0 Universal
nickname: CC0 1.0 Universal
category: Public Domain Dedication category: Public Domain Dedication
tab-slug: cc0 tab-slug: cc0
permalink: /licenses/cc0/ permalink: /licenses/cc0/
@ -25,6 +26,8 @@ permitted:
forbidden: forbidden:
- no-liability - no-liability
required: []
--- ---
CC0 1.0 Universal CC0 1.0 Universal

View File

@ -1,8 +1,9 @@
--- ---
layout: license layout: license
title: Eclipse Public License v1.0 title: Eclipse Public License 1.0
category: Eclipse category: Eclipse
permalink: /licenses/eclipse/ redirect_from: /licenses/eclipse/
permalink: /licenses/epl-1.0/
description: This commercially-friendly copyleft license provides the ability to commercially license binaries; a modern royalty-free patent license grant; and the ability for linked works to use other licenses, including commercial ones. description: This commercially-friendly copyleft license provides the ability to commercially license binaries; a modern royalty-free patent license grant; and the ability for linked works to use other licenses, including commercial ones.

View File

@ -1,10 +1,12 @@
--- ---
title: GPL v2 title: GNU General Public License v2.0
nickname: GNU GPL v2.0
category: GPL category: GPL
tab-slug: gpl-v2 tab-slug: gpl-v2
hide-from-license-list: false hide-from-license-list: false
layout: license layout: license
permalink: /licenses/gpl-v2/ permalink: /licenses/gpl-2.0/
redirect_from: /licenses/gpl-v2/
source: http://www.gnu.org/licenses/gpl-2.0.txt source: http://www.gnu.org/licenses/gpl-2.0.txt
description: GPL is the most widely used free software license and has a strong copyleft requirement. When distributing derived works, the source code of the work must be made available under the same license. There are multiple variants of the GPL, each with different requirements. description: GPL is the most widely used free software license and has a strong copyleft requirement. When distributing derived works, the source code of the work must be made available under the same license. There are multiple variants of the GPL, each with different requirements.

View File

@ -1,12 +1,16 @@
--- ---
title: GPL v3 title: GNU General Public License v3.0
nickname: GNU GPL v3.0
category: GPL category: GPL
tab-slug: gpl-v3 tab-slug: gpl-v3
hide-from-license-list: true hide-from-license-list: true
layout: license layout: license
permalink: /licenses/gpl-v3/ permalink: /licenses/gpl-3.0/
redirect_from: /licenses/gpl-v3/
source: http://www.gnu.org/licenses/gpl-3.0.txt source: http://www.gnu.org/licenses/gpl-3.0.txt
description: GPL is the most widely used free software license and has a strong copyleft requirement. When distributing derived works, the source code of the work must be made available under the same license.
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. 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.
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. 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.

42
_licenses/isc.txt Normal file
View File

@ -0,0 +1,42 @@
---
layout: license
title: ISC License
permalink: /licenses/isc/
source: http://opensource.org/licenses/isc-license
category: BSD
tab-slug: isc
description: A permissive license lets people do anything with your code with proper attribution and without warranty. The ISC license is functionally equivalent to the <a href="/licenses/bsd">BSD 2-Clause</a> and <a href="/licenses/mit">MIT</a> licenses, removing some language that is no longer necessary.
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. [email] is optional but recommended.
filename: LICENSE
required:
- include-copyright
permitted:
- commercial-use
- distribution
- modifications
- private-use
- sublicense
forbidden:
- no-liability
---
Copyright (c) [year], [fullname] <[email]>
Permission to use, copy, modify, and/or distribute this software for any
purpose with or without fee is hereby granted, provided that the above
copyright notice and this permission notice appear in all copies.
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.

View File

@ -1,9 +1,11 @@
--- ---
layout: license layout: license
title: LGPL v2.1 title: GNU Lesser General Public License v2.1
nickname: GNU LGPL v2.1
category: LGPL category: LGPL
tab-slug: lgpl-v2_1 tab-slug: lgpl-v2_1
permalink: /licenses/lgpl-v2.1/ redirect_from: /licenses/lgpl-v2.1/
permalink: /licenses/lgpl-2.1/
source: http://www.gnu.org/licenses/lgpl-2.1.txt source: http://www.gnu.org/licenses/lgpl-2.1.txt
description: Primarily used for software libraries, LGPL requires that derived works be licensed under the same license, but works that only link to it do not fall under this restriction. There are two commonly used versions of the LGPL. description: Primarily used for software libraries, LGPL requires that derived works be licensed under the same license, but works that only link to it do not fall under this restriction. There are two commonly used versions of the LGPL.

View File

@ -1,17 +1,19 @@
--- ---
layout: license layout: license
title: LGPL v3 title: GNU Lesser General Public License v3.0
nickname: GNU LGPL v3.0
category: LGPL category: LGPL
tab-slug: lgpl-v3 tab-slug: lgpl-v3
hide-from-license-list: true hide-from-license-list: true
permalink: /licenses/lgpl-v3/ redirect_from: /licenses/lgpl-v3/
source: http://www.gnu.org/licenses/lgpl-3.0.txt source: http://www.gnu.org/licenses/lgpl-3.0.txt
permalink: /licenses/lgpl-3.0/
description: Version 3 of the LGPL is an additional set of permissions to the <a href="/licenses/gpl-v3">GPL v3 license</a> that requires that derived works be licensed under the same license, but works that only link to it do not fall under this restriction. description: Version 3 of the LGPL is an additional set of permissions to the <a href="/licenses/GPL-3.0">GPL v3 license</a> that requires that derived works be licensed under the same license, but works that only link to it do not fall under this restriction.
how: This license is an additional set of permissions to the <a href="/licenses/gpl-v3">GPL v3</a> license. Follow the instructions to apply the GPL v3 license. Then either paste this text to the bottom of that file OR add a separate file (typically named COPYING.lesser or LICENSE.lesser) in the root of your source code and copy the text. how: This license is an additional set of permissions to the <a href="/licenses/gpl-3.0">GPL v3</a> license. Follow the instructions to apply the GPL v3. Then either paste this text to the bottom of the created file OR add a separate file (typically named COPYING.lesser or LICENSE.lesser) in the root of your source code and copy the text.
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. 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 <a href="/licenses/gpl-3.0">GPL v3 license</a>. Insert the word “Lesser” before “General” in all three places in the boilerplate notice to make sure that you refer to the LGPL v3 and not the GPL v3.
required: required:
- include-copyright - include-copyright

View File

@ -1,9 +1,10 @@
--- ---
layout: license layout: license
title: Mozilla Public License Version 2.0 title: Mozilla Public License 2.0
category: Mozilla category: Mozilla
permalink: /licenses/mozilla/ redirect_from: /licenses/mozilla/
source: http://www.mozilla.org/MPL/2.0/ source: http://www.mozilla.org/MPL/2.0/
permalink: /licenses/mpl-2.0/
description: The Mozilla Public License (MPL 2.0) is maintained by the Mozilla foundation. This license attempts to be a compromise between the permissive BSD license and the reciprocal GPL license. description: The Mozilla Public License (MPL 2.0) is maintained by the Mozilla foundation. This license attempts to be a compromise between the permissive BSD license and the reciprocal GPL license.

View File

@ -16,14 +16,17 @@ how: Create a text file (typically named UNLICENSE or UNLICENSE.txt) in the root
required: required:
permitted: permitted:
- private-use
- commercial-use - commercial-use
- modifications - modifications
- distribution - distribution
- private-use - sublicense
forbidden: forbidden:
- no-liability - no-liability
required: []
--- ---
This is free and unencumbered software released into the public domain. This is free and unencumbered software released into the public domain.

1
_sass/jquery.qtip.scss Symbolic link
View File

@ -0,0 +1 @@
../assets/vendor/qtip2/jquery.qtip.css

1
_sass/normalize.scss vendored Symbolic link
View File

@ -0,0 +1 @@
../assets/vendor/normalize-css/normalize.css

View File

@ -1,3 +1,9 @@
---
---
@import "normalize";
@import "jquery.qtip";
body { body {
background-image: url(../img/bg.jpg); background-image: url(../img/bg.jpg);
color: #5c5855; color: #5c5855;
@ -22,7 +28,7 @@ h1, h2, h3, h5 {
} }
h1 { h1 {
font-size: 40px; font-size: 35px;
margin-bottom: 25px; margin-bottom: 25px;
} }

View File

@ -1,3 +1,6 @@
---
---
class Choosealicense class Choosealicense
# Checks if Flash is available in the client. # Checks if Flash is available in the client.
@ -42,9 +45,9 @@ class Choosealicense
initTooltips: -> initTooltips: ->
# Dynamically add annotations as title attribute to rule list items # Dynamically add annotations as title attribute to rule list items
for category, rules of annotations for category, rules of window.annotations
for label, text of rules for rule in rules
$(".license-rules ul.license-#{category} li.#{label}").attr "title", text $(".license-rules ul.license-#{category} li.#{rule["tag"]}").attr "title", rule["description"]
# Init tooltips on all rule list items # Init tooltips on all rule list items
for category, label of @categories for category, label of @categories
@ -87,11 +90,11 @@ class Choosealicense
# Callback to restore the clipboard button's original text # Callback to restore the clipboard button's original text
clipboardMouseout: (client, args) -> clipboardMouseout: (client, args) ->
@innerText = $(this).data("clipboard-prompt") @textContent = $(this).data("clipboard-prompt")
# Post-copy user feedback callback # Post-copy user feedback callback
clipboardComplete: (client, args) -> clipboardComplete: (client, args) ->
@innerText = "Copied!" @textContent = "Copied!"
# Initializes pill navigation for license variations # Initializes pill navigation for license variations
initLicenseVariationNav: -> initLicenseVariationNav: ->

View File

@ -1,6 +0,0 @@
---
layout: nil
---
{% include js/annotations.js %}
{% include js/app.js %}

View File

@ -2,7 +2,7 @@
layout: default layout: default
class: home class: home
hide_breadcrumbs: true hide_breadcrumbs: true
title: Choosing an OSS license doesn't need to be scary title: Choosing an OSS license doesnt need to be scary
description: A site to provide non-judgmental guidance on choosing a license for your open source project description: A site to provide non-judgmental guidance on choosing a license for your open source project
permalink: / permalink: /
--- ---
@ -19,31 +19,31 @@ permalink: /
<h3>I want it simple and permissive.</h3> <h3>I want it simple and permissive.</h3>
</a> </a>
<p> <p>
The <a href="licenses/mit">MIT License</a> is a permissive license that is short and to the point. It lets people do anything they want with your code as long as they provide attribution back to you and don't hold you liable. The <a href="licenses/mit">MIT License</a> is a permissive license that is short and to the point. It lets people do anything they want with your code as long as they provide attribution back to you and dont hold you liable.
</p> </p>
<p> <p>
<strong>jQuery</strong> and <strong>Rails</strong> use the MIT&nbsp;License. <strong>jQuery</strong> and <strong>Rails</strong> use the MIT&nbsp;License.
</p> </p>
</li> </li>
<li class="patents"> <li class="patents">
<a href="licenses/apache"> <a href="licenses/apache-2.0/">
<span class="triptych-sprite lightbulb"></span> <span class="triptych-sprite lightbulb"></span>
<h3>I'm concerned about patents.</h3> <h3>Im concerned about patents.</h3>
</a> </a>
<p> <p>
The <a href="licenses/apache/">Apache License</a> is a permissive license similar to the MIT License, but also provides an express grant of patent rights from contributors to users. The <a href="licenses/apache-2.0/">Apache License</a> is a permissive license similar to the MIT License, but also provides an express grant of patent rights from contributors to users.
</p> </p>
<p> <p>
<strong>Apache</strong>, <strong>SVN</strong>, and <strong>NuGet</strong> use the Apache&nbsp;License. <strong>Apache</strong>, <strong>SVN</strong>, and <strong>NuGet</strong> use the Apache&nbsp;License.
</p> </p>
</li> </li>
<li class="copyleft"> <li class="copyleft">
<a href="licenses/gpl-v2"> <a href="licenses/gpl-2.0/">
<span class="triptych-sprite circular"></span> <span class="triptych-sprite circular"></span>
<h3>I care about sharing improvements.</h3> <h3>I care about sharing improvements.</h3>
</a> </a>
<p> <p>
The GPL (<a href="licenses/gpl-v2">V2</a> or <a href="licenses/gpl-v3">V3</a>) is a copyleft license that requires anyone who distributes your code or a derivative work to make the source available under the same terms. V3 is similar to V2, but further restricts use in hardware that forbids software alterations. The GPL (<a href="licenses/gpl-2.0/">V2</a> or <a href="licenses/gpl-3.0/">V3</a>) is a copyleft license that requires anyone who distributes your code or a derivative work to make the source available under the same terms. V3 is similar to V2, but further restricts use in hardware that forbids software alterations.
</p> </p>
<p> <p>
<strong>Linux</strong>, <strong>Git</strong>, and <strong>WordPress</strong> use the GPL. <strong>Linux</strong>, <strong>Git</strong>, and <strong>WordPress</strong> use the GPL.
@ -57,7 +57,7 @@ permalink: /
</h2> </h2>
<ul class="triptych see-more clearfix"> <ul class="triptych see-more clearfix">
<li> <li>
<h3>My content isn't code.</h3> <h3>My content isnt code.</h3>
<p> <p>
Check out <a href="http://creativecommons.org/choose/">Creative Commons</a>. Check out <a href="http://creativecommons.org/choose/">Creative Commons</a>.
</p> </p>
@ -69,9 +69,9 @@ permalink: /
</p> </p>
</li> </li>
<li> <li>
<h3>I don't want to choose a license.</h3> <h3>I dont want to choose a license.</h3>
<p> <p>
<a href="no-license">You don't have to</a>. <a href="no-license">You dont have to</a>.
</p> </p>
</li> </li>
</ul> </ul>

View File

@ -7,14 +7,9 @@ title: Licenses
<h2>Featured Licenses</h2> <h2>Featured Licenses</h2>
{% assign sorted_pages = site.pages | sort: 'path' %} {% assign featured_licenses = site.licenses | where:"featured",true %}
{% for license in featured_licenses | sort: 'path' %}
{% for page in sorted_pages %}
{% if page.layout == "license" %}
{% if page.featured %}
{% include license-overview.html %} {% include license-overview.html %}
{% endif %}
{% endif %}
{% endfor %} {% endfor %}
<h2>Other licenses</h2> <h2>Other licenses</h2>
@ -22,11 +17,7 @@ title: Licenses
Some communities tend to have specific licenses preferred by the Some communities tend to have specific licenses preferred by the
community. For example, Perl developers often choose the Artistic License. community. For example, Perl developers often choose the Artistic License.
</p> </p>
{% assign licenses = site.licenses | where:"featured",false | where:"hide-from-license-list",false %}
{% for page in sorted_pages %} {% for license in licenses %}
{% if page.layout == "license" %}
{% if page.featured != true and page.hide-from-license-list != true %}
{% include license-overview.html %} {% include license-overview.html %}
{% endif %}
{% endif %}
{% endfor %} {% endfor %}

View File

@ -1,28 +1,4 @@
--- ---
comment: \
because the for loop is being filtered by layout, the normal rindex0 check
for the trailing comma doesn't work. Count the number of licenses and manually
increment an index to see if we're on the true last iteration.
--- ---
{% assign count = 0 %}{% for page in site.pages %}{% if page.layout == "license" %}{% assign count = count | plus: 1 %}{% endif %}{% endfor %}{% assign i = 0 %}
[ {{ site.licenses | jsonify }}
{% for page in site.pages %}{% if page.layout == "license" %}
{
"title": "{{ page.title }}",
"permalink": "{{ page.permalink }}",
"featured": {% if page.featured %}true{% else %}false{% endif %},
"description": "{{ page.description | replace: '"', '\"' }}",
"how": "{{ page.how | replace: '"', '\"' }}",
"rules": {
{% for category in site.rules %}
{% assign cat = category[0] %}
"{{ cat }}": [
{% for rule in page[cat] %}
"{{ rule }}"{% if forloop.rindex0 > 0 %},{% endif %}
{% endfor %}
]{% if forloop.rindex0 > 0 %},{% endif %}
{% endfor %}
}{% assign i = i | plus: 1 %}
}{% if i < count %},{% endif %}
{% endif %}{% endfor %}
]

View File

@ -6,8 +6,8 @@ title: No License
You're under no obligation to choose a license and it's your right not to include one with your code or project. But please note that opting out of open source licenses doesn't mean you're opting out of copyright law. You're under no obligation to choose a license and it's your right not to include one with your code or project. But please note that opting out of open source licenses doesn't mean you're opting out of copyright law.
You'll have to check with your own legal counsel regarding your particular project, but generally speaking, the absence of a license means that default copyright laws apply. This means that you retain all rights to your source code and that nobody else may reproduce, distribute, or create derivative works from your work. This might not be what you intend. You'll have to check with your own legal counsel regarding your particular project, but generally speaking, the absence of a license means that default copyright laws apply. This means that you retain all rights to your source code and that nobody else may reproduce, distribute, or create derivative works from your work.
Disallowing use of your code might not be what you intend by "no license." An [open-source license](/) allows reuse of your code while maintaining copyright. If your goal is to explicitly opt-out of copyright protections, try a public domain dedication like the [Unlicense](/licenses/unlicense/) or [CC0](/licenses/cc0). If you want to share your work with others, you must opt into it.
Even in the absence of a license file, you may grant some rights in cases where you publish your source code to a site that requires accepting terms of service. For example, if you publish your source code in a public repository on GitHub, you have accepted the [Terms of Service](https://help.github.com/articles/github-terms-of-service) which do allow other GitHub users some rights. Specifically, you allow others to view and fork your repository. Even in the absence of a license file, you may grant some rights in cases where you publish your source code to a site that requires accepting terms of service. For example, if you publish your source code in a public repository on GitHub, you have accepted the [Terms of Service](https://help.github.com/articles/github-terms-of-service) which do allow other GitHub users some rights. Specifically, you allow others to view and fork your repository.
If you want to share your work with others, please consider choosing an open source license.

View File

@ -1,5 +1,4 @@
--- ---
layout: nil
--- ---
# www.robotstxt.org/ # www.robotstxt.org/

View File

@ -6,8 +6,5 @@ echo "bundling installin'"
gem install bundler gem install bundler
bundle install bundle install
echo "npm installin'"
npm install coffee-script
echo echo
echo "You're all set. Just run script/server and you can play license roulette!" echo "You're all set. Just run script/server and you can play license roulette!"

View File

@ -2,8 +2,5 @@
set -e set -e
echo "compiling javascript..."
./node_modules/.bin/coffee -c _includes/js/app.coffee
echo "building the site..." echo "building the site..."
bundle exec rake test bundle exec rake test

7
script/downcase Executable file
View File

@ -0,0 +1,7 @@
#! /usr/bin/env ruby
# downcases all licenses in a git-friendly way
Dir["_licenses/*"].each do |file|
system "git mv #{file} #{file.downcase}2"
system "git mv #{file.downcase}2 #{file.downcase}"
end

View File

@ -2,9 +2,6 @@
set -e set -e
echo "compiling javascript..."
./node_modules/.bin/coffee -c _includes/js/app.coffee
echo "spinning up the server..." echo "spinning up the server..."
bundle exec jekyll serve -w bundle exec jekyll serve -w

51
spec/license_spec.rb Normal file
View File

@ -0,0 +1,51 @@
require 'spec_helper'
licenses.each do |license|
describe "The #{license["title"]} license" do
it "should have a title" do
expect(license["title"]).to_not be_nil
end
it "should have a description" do
expect(license["description"]).to_not be_nil
end
describe "SPDX compliance" do
# "No license" isn't really a license, so no need to test
unless license["id"] == "no-license"
it "#{license["id"]} should be a valid SPDX ID" do
expect(find_spdx(license["id"])).to_not be_nil
end
it "should be the proper SPDX name" do
spdx = find_spdx(license["id"])
expect(spdx[1]["name"].gsub(/ only$/,"")).to eql(license["title"])
end
# CC0 and Unlicense are not OSI approved, but that's okay
unless license["id"] == "unlicense" || license["id"] == "cc0-1.0"
it "should be OSI approved" do
spdx = find_spdx(license["id"])
expect(spdx[1]["osiApproved"]).to eql(true)
end
end
end
end
["permitted", "required", "forbidden"].each do |group|
describe "#{group} properties" do
it "should list the properties" do
expect(license[group]).to_not be_nil
end
license[group].to_a.each do |tag|
describe "#{tag} tag" do
it "should be a valid tag" do
expect(rule?(tag,group)).to be(true)
end
end
end
end
end
end
end

47
spec/spec_helper.rb Normal file
View File

@ -0,0 +1,47 @@
require 'jekyll'
require 'open-uri'
require 'json'
def config_file
File.expand_path "./_config.yml", source
end
def source
File.expand_path("../", File.dirname(__FILE__))
end
def config
config = Jekyll::Configuration.new.read_config_file config_file
config = Jekyll::Utils.deep_merge_hashes(config, {:source => source})
Jekyll::Utils.deep_merge_hashes(Jekyll::Configuration::DEFAULTS, config)
end
def licenses
site.collections["licenses"].docs.map { |l| l.data.merge("id" => l.basename(".txt")) }
end
def site
$site ||= begin
site = Jekyll::Site.new(config)
site.reset
site.read
site
end
end
def rules
site.data["rules"]
end
def rule?(tag, group)
rules[group].any? { |r| r["tag"] == tag }
end
def spdx_list
url = "https://raw.githubusercontent.com/sindresorhus/spdx-license-list/master/spdx.json"
$spdx ||= JSON.parse(open(url).read)
end
def find_spdx(license)
spdx_list.find { |name, properties| name.downcase == license }
end