licenser 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/bin/license +5 -0
- data/data/apache2 +201 -0
- data/data/apache2.notice +13 -0
- data/data/bsd3 +27 -0
- data/data/gplv2 +339 -0
- data/data/gplv2.notice +16 -0
- data/data/gplv3 +674 -0
- data/data/gplv3.notice +15 -0
- data/data/lgplv3 +165 -0
- data/data/mpl +310 -0
- data/data/x11 +27 -0
- data/lib/license.rb +5 -0
- data/lib/license/license.rb +19 -0
- data/lib/license/licenses.rb +6 -0
- data/lib/license/opt_parse.rb +18 -0
- metadata +60 -0
data/data/x11
ADDED
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
Copyright (C) 1996 X Consortium
|
|
2
|
+
|
|
3
|
+
Permission is hereby granted, free of charge, to any person obtaining
|
|
4
|
+
a copy of this software and associated documentation files (the
|
|
5
|
+
"Software"), to deal in the Software without restriction, including
|
|
6
|
+
without limitation the rights to use, copy, modify, merge, publish,
|
|
7
|
+
distribute, sublicense, and/or sell copies of the Software, and to
|
|
8
|
+
permit persons to whom the Software is furnished to do so, subject to
|
|
9
|
+
the following conditions:
|
|
10
|
+
|
|
11
|
+
The above copyright notice and this permission notice shall be
|
|
12
|
+
included in all copies or substantial portions of the Software.
|
|
13
|
+
|
|
14
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
|
15
|
+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
|
16
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
|
17
|
+
NONINFRINGEMENT. IN NO EVENT SHALL THE X CONSORTIUM BE LIABLE FOR ANY
|
|
18
|
+
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
|
|
19
|
+
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
|
20
|
+
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
|
21
|
+
|
|
22
|
+
Except as contained in this notice, the name of the X Consortium shall
|
|
23
|
+
not be used in advertising or otherwise to promote the sale, use or
|
|
24
|
+
other dealings in this Software without prior written authorization
|
|
25
|
+
from the X Consortium.
|
|
26
|
+
|
|
27
|
+
X Window System is a trademark of X Consortium, Inc.
|
data/lib/license.rb
ADDED
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
require 'fileutils'
|
|
2
|
+
|
|
3
|
+
module License
|
|
4
|
+
class LicenseObject
|
|
5
|
+
def initialize(license, outfile = "LICENSE")
|
|
6
|
+
@license = license
|
|
7
|
+
@outfile = outfile
|
|
8
|
+
end
|
|
9
|
+
|
|
10
|
+
def parse_license
|
|
11
|
+
if License::LICENSES.include? @license
|
|
12
|
+
FileUtils.cp("data/#{@license}", "#{@outfile}")
|
|
13
|
+
else
|
|
14
|
+
puts "Unsupported license please use --list to show all supported licenses"
|
|
15
|
+
exit
|
|
16
|
+
end
|
|
17
|
+
end
|
|
18
|
+
end
|
|
19
|
+
end
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
module License
|
|
2
|
+
class Application < Clamp::Command
|
|
3
|
+
option ["-l", "--list"], "", "List all supported licenses and exit" do
|
|
4
|
+
License::LICENSES.each do |license|
|
|
5
|
+
puts license
|
|
6
|
+
end
|
|
7
|
+
exit
|
|
8
|
+
end
|
|
9
|
+
|
|
10
|
+
option ["-o", "--outfile"], "OUT", "Specify license file name", :default => "LICENSE"
|
|
11
|
+
|
|
12
|
+
parameter "LICENSE", "Name of license that is to be inserted. Use --list to see a list of available licenses", :attribute_name => :license
|
|
13
|
+
|
|
14
|
+
def execute
|
|
15
|
+
License::LicenseObject.new(license, outfile).parse_license
|
|
16
|
+
end
|
|
17
|
+
end
|
|
18
|
+
end
|
metadata
ADDED
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
|
2
|
+
name: licenser
|
|
3
|
+
version: !ruby/object:Gem::Version
|
|
4
|
+
version: 0.1.0
|
|
5
|
+
platform: ruby
|
|
6
|
+
authors:
|
|
7
|
+
- Eric Skoglund
|
|
8
|
+
autorequire:
|
|
9
|
+
bindir: bin
|
|
10
|
+
cert_chain: []
|
|
11
|
+
date: 2015-05-01 00:00:00.000000000 Z
|
|
12
|
+
dependencies: []
|
|
13
|
+
description: License creates license files for your project automatically so that
|
|
14
|
+
you don't need to do that manually
|
|
15
|
+
email: eric@pagefault.se
|
|
16
|
+
executables:
|
|
17
|
+
- license
|
|
18
|
+
extensions: []
|
|
19
|
+
extra_rdoc_files: []
|
|
20
|
+
files:
|
|
21
|
+
- bin/license
|
|
22
|
+
- data/apache2
|
|
23
|
+
- data/apache2.notice
|
|
24
|
+
- data/bsd3
|
|
25
|
+
- data/gplv2
|
|
26
|
+
- data/gplv2.notice
|
|
27
|
+
- data/gplv3
|
|
28
|
+
- data/gplv3.notice
|
|
29
|
+
- data/lgplv3
|
|
30
|
+
- data/mpl
|
|
31
|
+
- data/x11
|
|
32
|
+
- lib/license.rb
|
|
33
|
+
- lib/license/license.rb
|
|
34
|
+
- lib/license/licenses.rb
|
|
35
|
+
- lib/license/opt_parse.rb
|
|
36
|
+
homepage: http://github.com/EricIO/license
|
|
37
|
+
licenses:
|
|
38
|
+
- GPLv3
|
|
39
|
+
metadata: {}
|
|
40
|
+
post_install_message:
|
|
41
|
+
rdoc_options: []
|
|
42
|
+
require_paths:
|
|
43
|
+
- lib
|
|
44
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
|
45
|
+
requirements:
|
|
46
|
+
- - ">="
|
|
47
|
+
- !ruby/object:Gem::Version
|
|
48
|
+
version: '0'
|
|
49
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
|
50
|
+
requirements:
|
|
51
|
+
- - ">="
|
|
52
|
+
- !ruby/object:Gem::Version
|
|
53
|
+
version: '0'
|
|
54
|
+
requirements: []
|
|
55
|
+
rubyforge_project:
|
|
56
|
+
rubygems_version: 2.2.2
|
|
57
|
+
signing_key:
|
|
58
|
+
specification_version: 4
|
|
59
|
+
summary: Inserts license information for your project
|
|
60
|
+
test_files: []
|