maintainers 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.gitignore +11 -0
- data/.rspec +2 -0
- data/.travis.yml +5 -0
- data/CHANGELOG +13 -0
- data/CODE_OF_CONDUCT.md +49 -0
- data/Gemfile +4 -0
- data/LICENSE +15 -0
- data/MAINTAINERS-example +23 -0
- data/MAINTAINERS-unmaintained_example +6 -0
- data/README.md +77 -0
- data/Rakefile +6 -0
- data/bin/console +14 -0
- data/bin/maintainers +6 -0
- data/bin/setup +8 -0
- data/lib/maintainers.rb +6 -0
- data/lib/maintainers/cli.rb +103 -0
- data/lib/maintainers/runner.rb +104 -0
- data/lib/maintainers/version.rb +3 -0
- data/maintainers.gemspec +25 -0
- data/schema/MAINTAINERS.json +49 -0
- data/schema/json-meta-schema.json +150 -0
- metadata +134 -0
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: 00b5563bf03da3f38572a1d7fab70e85428be527
|
4
|
+
data.tar.gz: ac2790a0e8c9f490f37e93aac6d4d92c86610eb6
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: 8512cc947830ee68b07dbe1e4e0568dd9d4b03ff1c8fe83076e6b79899c84e8c8811d6cd45bb117ed4db6fcc8d756b14a7212c29c5b063aa9b9f5cc0009884c8
|
7
|
+
data.tar.gz: 35c1ea16c92a2c34350e8cb1b6204af30f1125993cf576100f9b78f7d090df9edc37777a4b78c835897d3770982e72d634cc658452c3eb9a0dd26c0fd1707d79
|
data/.gitignore
ADDED
data/.rspec
ADDED
data/.travis.yml
ADDED
data/CHANGELOG
ADDED
@@ -0,0 +1,13 @@
|
|
1
|
+
# Change Log
|
2
|
+
All notable changes to this project will be documented in this file.
|
3
|
+
|
4
|
+
The format is based on [Keep a Changelog](http://keepachangelog.com/)
|
5
|
+
and this project adheres to [Semantic Versioning](http://semver.org/).
|
6
|
+
|
7
|
+
## [Unreleased]
|
8
|
+
|
9
|
+
## 0.1.0 - 2016-09-01
|
10
|
+
### Added
|
11
|
+
- Initial support for a json format for MAINTAINERS
|
12
|
+
|
13
|
+
[Unreleased]: https://github.com/puppetlabs/maintainers/compare/v0.1.0...HEAD
|
data/CODE_OF_CONDUCT.md
ADDED
@@ -0,0 +1,49 @@
|
|
1
|
+
# Contributor Code of Conduct
|
2
|
+
|
3
|
+
As contributors and maintainers of this project, and in the interest of
|
4
|
+
fostering an open and welcoming community, we pledge to respect all people who
|
5
|
+
contribute through reporting issues, posting feature requests, updating
|
6
|
+
documentation, submitting pull requests or patches, and other activities.
|
7
|
+
|
8
|
+
We are committed to making participation in this project a harassment-free
|
9
|
+
experience for everyone, regardless of level of experience, gender, gender
|
10
|
+
identity and expression, sexual orientation, disability, personal appearance,
|
11
|
+
body size, race, ethnicity, age, religion, or nationality.
|
12
|
+
|
13
|
+
Examples of unacceptable behavior by participants include:
|
14
|
+
|
15
|
+
* The use of sexualized language or imagery
|
16
|
+
* Personal attacks
|
17
|
+
* Trolling or insulting/derogatory comments
|
18
|
+
* Public or private harassment
|
19
|
+
* Publishing other's private information, such as physical or electronic
|
20
|
+
addresses, without explicit permission
|
21
|
+
* Other unethical or unprofessional conduct
|
22
|
+
|
23
|
+
Project maintainers have the right and responsibility to remove, edit, or
|
24
|
+
reject comments, commits, code, wiki edits, issues, and other contributions
|
25
|
+
that are not aligned to this Code of Conduct, or to ban temporarily or
|
26
|
+
permanently any contributor for other behaviors that they deem inappropriate,
|
27
|
+
threatening, offensive, or harmful.
|
28
|
+
|
29
|
+
By adopting this Code of Conduct, project maintainers commit themselves to
|
30
|
+
fairly and consistently applying these principles to every aspect of managing
|
31
|
+
this project. Project maintainers who do not follow or enforce the Code of
|
32
|
+
Conduct may be permanently removed from the project team.
|
33
|
+
|
34
|
+
This code of conduct applies both within project spaces and in public spaces
|
35
|
+
when an individual is representing the project or its community.
|
36
|
+
|
37
|
+
Instances of abusive, harassing, or otherwise unacceptable behavior may be
|
38
|
+
reported by contacting a project maintainer at kylo@puppet.com. All
|
39
|
+
complaints will be reviewed and investigated and will result in a response that
|
40
|
+
is deemed necessary and appropriate to the circumstances. Maintainers are
|
41
|
+
obligated to maintain confidentiality with regard to the reporter of an
|
42
|
+
incident.
|
43
|
+
|
44
|
+
This Code of Conduct is adapted from the [Contributor Covenant][homepage],
|
45
|
+
version 1.3.0, available at
|
46
|
+
[http://contributor-covenant.org/version/1/3/0/][version]
|
47
|
+
|
48
|
+
[homepage]: http://contributor-covenant.org
|
49
|
+
[version]: http://contributor-covenant.org/version/1/3/0/
|
data/Gemfile
ADDED
data/LICENSE
ADDED
@@ -0,0 +1,15 @@
|
|
1
|
+
Maintainers - a gem for maintaining MAINTAINERS files
|
2
|
+
|
3
|
+
Copyright (C) 2016 Puppet, Inc.
|
4
|
+
|
5
|
+
Licensed under the Apache License, Version 2.0 (the "License");
|
6
|
+
you may not use this file except in compliance with the License.
|
7
|
+
You may obtain a copy of the License at
|
8
|
+
|
9
|
+
https://www.apache.org/licenses/LICENSE-2.0
|
10
|
+
|
11
|
+
Unless required by applicable law or agreed to in writing, software
|
12
|
+
distributed under the License is distributed on an "AS IS" BASIS,
|
13
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
14
|
+
See the License for the specific language governing permissions and
|
15
|
+
limitations under the License.
|
data/MAINTAINERS-example
ADDED
@@ -0,0 +1,23 @@
|
|
1
|
+
{
|
2
|
+
"version": 1,
|
3
|
+
"issues": "https://github.com/graceland/issues",
|
4
|
+
"people": [
|
5
|
+
{
|
6
|
+
"github": "gracehopper",
|
7
|
+
"email": "admiral.grace.hopper@usnavy.gov",
|
8
|
+
"name": "Grace Hopper",
|
9
|
+
"comment": "Maintains ENIAC subsystem"
|
10
|
+
},
|
11
|
+
{
|
12
|
+
"github": "turing",
|
13
|
+
"email": "at@cambridge.edu",
|
14
|
+
"name": "Alan Turing",
|
15
|
+
"comment": "Passed his own test"
|
16
|
+
},
|
17
|
+
{
|
18
|
+
"github": "ada",
|
19
|
+
"email": "ada@example.com",
|
20
|
+
"name": "Ada Lovelace"
|
21
|
+
}
|
22
|
+
]
|
23
|
+
}
|
data/README.md
ADDED
@@ -0,0 +1,77 @@
|
|
1
|
+
# Maintainers
|
2
|
+
|
3
|
+
This is a gem for maintaining MAINTAINERS files.
|
4
|
+
|
5
|
+
## Installation
|
6
|
+
|
7
|
+
```ruby
|
8
|
+
$ gem install maintainers
|
9
|
+
```
|
10
|
+
|
11
|
+
## Usage
|
12
|
+
|
13
|
+
Some use cases:
|
14
|
+
|
15
|
+
### Create an empty MAINTAINERS file
|
16
|
+
|
17
|
+
The only top-level configurable you might want to specify is the issues url.
|
18
|
+
|
19
|
+
```ruby
|
20
|
+
maintainers create --issues https://github.com/gracehopper/newthing/issues
|
21
|
+
```
|
22
|
+
|
23
|
+
At this point you might drop some comments in the resultant MAINTAINERS file.
|
24
|
+
|
25
|
+
### Add or remove a maintainer from a MAINTAINERS file
|
26
|
+
|
27
|
+
Add users, optionally as a subsystem maintainer, optionally with a comment:
|
28
|
+
|
29
|
+
```ruby
|
30
|
+
maintainers add --github gracehopper --email grace@usnavy.gov --name "Grace Hopper"
|
31
|
+
maintainers add --github gracehopper --email grace@usnavy.gov --name "Grace Hopper" --subsystem --comment "Maintains ENIAC"
|
32
|
+
```
|
33
|
+
|
34
|
+
Remove user by specifying the github id:
|
35
|
+
|
36
|
+
```ruby
|
37
|
+
maintainers remove --github gracehopper
|
38
|
+
```
|
39
|
+
|
40
|
+
### List maintainers from a MAINTAINERS file
|
41
|
+
|
42
|
+
Emit a list of maintainers:
|
43
|
+
|
44
|
+
```ruby
|
45
|
+
maintainers list
|
46
|
+
```
|
47
|
+
|
48
|
+
### List maintainers for a repo
|
49
|
+
|
50
|
+
Emit a list of maintainers:
|
51
|
+
|
52
|
+
```ruby
|
53
|
+
maintainers list https://github.com/gracehopper/newthing
|
54
|
+
```
|
55
|
+
|
56
|
+
### Produce a summary report of maintainers within an org
|
57
|
+
|
58
|
+
```ruby
|
59
|
+
maintainers report https://github.com/gracehopper
|
60
|
+
```
|
61
|
+
|
62
|
+
### Report all repos in an org maintained by someone
|
63
|
+
|
64
|
+
```ruby
|
65
|
+
maintainers report --github gracehopper https://github.com/gracehopper
|
66
|
+
```
|
67
|
+
|
68
|
+
## Development
|
69
|
+
|
70
|
+
After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake spec` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
|
71
|
+
|
72
|
+
To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and tags, and push the `.gem` file to [rubygems.org](https://rubygems.org).
|
73
|
+
|
74
|
+
## Contributing
|
75
|
+
|
76
|
+
Bug reports and pull requests are welcome on GitHub at https://github.com/puppetlabs/maintainers. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [Contributor Covenant](http://contributor-covenant.org) code of conduct.
|
77
|
+
|
data/Rakefile
ADDED
data/bin/console
ADDED
@@ -0,0 +1,14 @@
|
|
1
|
+
#!/usr/bin/env ruby
|
2
|
+
|
3
|
+
require "bundler/setup"
|
4
|
+
require "maintainers"
|
5
|
+
|
6
|
+
# You can add fixtures and/or initialization code here to make experimenting
|
7
|
+
# with your gem easier. You can also use a different console, if you like.
|
8
|
+
|
9
|
+
# (If you use this, don't forget to add pry to your Gemfile!)
|
10
|
+
# require "pry"
|
11
|
+
# Pry.start
|
12
|
+
|
13
|
+
require "irb"
|
14
|
+
IRB.start
|
data/bin/maintainers
ADDED
data/bin/setup
ADDED
data/lib/maintainers.rb
ADDED
@@ -0,0 +1,103 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
# frozen_string_literal: true
|
3
|
+
|
4
|
+
require 'optparse'
|
5
|
+
|
6
|
+
module Maintainers
|
7
|
+
# CLI entry point
|
8
|
+
class CLI
|
9
|
+
attr_reader :options
|
10
|
+
|
11
|
+
def initialize
|
12
|
+
@options = {}
|
13
|
+
end
|
14
|
+
|
15
|
+
def usage
|
16
|
+
puts "Imagine a usage statement here"
|
17
|
+
exit 1
|
18
|
+
end
|
19
|
+
|
20
|
+
SUBCOMMANDS_WE_LOVE = [
|
21
|
+
"create",
|
22
|
+
"add",
|
23
|
+
"remove",
|
24
|
+
"list",
|
25
|
+
"report",
|
26
|
+
"help",
|
27
|
+
"--help",
|
28
|
+
]
|
29
|
+
|
30
|
+
# @return [Hash] Return an options hash
|
31
|
+
def parse(args)
|
32
|
+
|
33
|
+
subcommands = {
|
34
|
+
'create' => OptionParser.new do |opts|
|
35
|
+
opts.on("-i", "--issues [ISSUES URL]", "issues url") do |v|
|
36
|
+
options[:issues] = v
|
37
|
+
end
|
38
|
+
end,
|
39
|
+
'add' => OptionParser.new do |opts|
|
40
|
+
opts.on("-g", "--github [GITHUB ID]", "github id") do |v|
|
41
|
+
options[:github] = v
|
42
|
+
end
|
43
|
+
opts.on("-e", "--email [EMAIL ADDRESS]", "email address") do |v|
|
44
|
+
options[:email] = v
|
45
|
+
end
|
46
|
+
opts.on("-n", "--name [REAL NAME]", "real name") do |v|
|
47
|
+
options[:name] = v
|
48
|
+
end
|
49
|
+
end,
|
50
|
+
'remove' => OptionParser.new do |opts|
|
51
|
+
opts.on("-g", "--github [GITHUB ID]", "github id") do |v|
|
52
|
+
options[:github] = v
|
53
|
+
end
|
54
|
+
end,
|
55
|
+
'list' => OptionParser.new do |opts|
|
56
|
+
end,
|
57
|
+
}
|
58
|
+
|
59
|
+
if args.count == 0
|
60
|
+
$stderr.puts "Give me some args please"
|
61
|
+
usage
|
62
|
+
end
|
63
|
+
|
64
|
+
subcommand = args.shift
|
65
|
+
options[:subcommand] = subcommand
|
66
|
+
|
67
|
+
unless subcommands.keys.include? subcommand
|
68
|
+
usage
|
69
|
+
end
|
70
|
+
|
71
|
+
subcommands[subcommand].order!
|
72
|
+
|
73
|
+
if subcommand == 'create' && options[:issues].nil?
|
74
|
+
$stderr.puts "Please specify --issues"
|
75
|
+
usage
|
76
|
+
end
|
77
|
+
|
78
|
+
if subcommand == 'add' && options[:github].nil?
|
79
|
+
$stderr.puts "Please specify --github"
|
80
|
+
usage
|
81
|
+
end
|
82
|
+
|
83
|
+
if args.count > 0
|
84
|
+
$stderr.puts "Unexpected additional args #{args}"
|
85
|
+
usage
|
86
|
+
end
|
87
|
+
|
88
|
+
options
|
89
|
+
end # parse()
|
90
|
+
|
91
|
+
# @return [Fixnum] exit code
|
92
|
+
def run(args = ARGV)
|
93
|
+
@options = parse(args)
|
94
|
+
|
95
|
+
runner = Runner.new(@options)
|
96
|
+
runner.run
|
97
|
+
rescue StandardError, SyntaxError => e
|
98
|
+
$stderr.puts e.message
|
99
|
+
$stderr.puts e.backtrace
|
100
|
+
return 1
|
101
|
+
end
|
102
|
+
end
|
103
|
+
end
|
@@ -0,0 +1,104 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
# frozen_string_literal: true
|
3
|
+
|
4
|
+
require 'json'
|
5
|
+
require 'json-schema'
|
6
|
+
|
7
|
+
module Maintainers
|
8
|
+
# Runner entry point
|
9
|
+
class Runner
|
10
|
+
def initialize(options)
|
11
|
+
@options = options
|
12
|
+
|
13
|
+
# for now just assume it's always MAINTAINERS
|
14
|
+
options[:filename] ||= 'MAINTAINERS'
|
15
|
+
end
|
16
|
+
|
17
|
+
# Run, Lola, Run
|
18
|
+
# @return nil
|
19
|
+
def run
|
20
|
+
case @options[:subcommand]
|
21
|
+
when 'create'
|
22
|
+
create(@options)
|
23
|
+
when 'add'
|
24
|
+
add(@options)
|
25
|
+
when 'remove'
|
26
|
+
remove(@options)
|
27
|
+
end
|
28
|
+
end
|
29
|
+
|
30
|
+
def validate(maintainers)
|
31
|
+
maintainers_schema = JSON.parse(File.read('schema/maintainers.json'))
|
32
|
+
|
33
|
+
JSON::Validator.validate(maintainers_schema, maintainers)
|
34
|
+
end
|
35
|
+
|
36
|
+
def write_file(filename, maintainers)
|
37
|
+
maintainers_json = JSON.pretty_generate(maintainers)
|
38
|
+
|
39
|
+
if !validate(maintainers_json)
|
40
|
+
$stderr.puts "Invalid maintainers string!"
|
41
|
+
exit 1
|
42
|
+
end
|
43
|
+
|
44
|
+
File.open(filename, 'w') { |f| f.write(maintainers_json) }
|
45
|
+
end
|
46
|
+
|
47
|
+
def create(options)
|
48
|
+
filename = options[:filename]
|
49
|
+
if File.exist?(filename)
|
50
|
+
$stderr.puts "#{filename} already exists. Remove it and then re-run this command."
|
51
|
+
exit 1
|
52
|
+
end
|
53
|
+
|
54
|
+
# minimum content for a maintainers file
|
55
|
+
maintainers = {}
|
56
|
+
maintainers["version"] = 1
|
57
|
+
maintainers["issues"] = options[:issues]
|
58
|
+
maintainers["people"] = []
|
59
|
+
|
60
|
+
write_file(filename, maintainers)
|
61
|
+
end
|
62
|
+
|
63
|
+
def add(options)
|
64
|
+
filename = options[:filename]
|
65
|
+
if !File.exist?(filename)
|
66
|
+
$stderr.puts "No #{filename} file exists yet. You can use the 'create' subcommand to create one."
|
67
|
+
exit 1
|
68
|
+
end
|
69
|
+
|
70
|
+
maintainers = JSON.load(File.read(filename))
|
71
|
+
new_maintainer = { "github" => options[:github] }
|
72
|
+
new_maintainer["email"] = options[:email] if options[:email]
|
73
|
+
new_maintainer["name"] = options[:name] if options[:name]
|
74
|
+
index = maintainers["people"].index { |person| person["github"] == options[:github] }
|
75
|
+
if index
|
76
|
+
current = maintainers["people"][index]
|
77
|
+
new_maintainer.merge! current
|
78
|
+
maintainers["people"][index] = new_maintainer
|
79
|
+
else
|
80
|
+
maintainers["people"] << new_maintainer
|
81
|
+
end
|
82
|
+
|
83
|
+
write_file(filename, maintainers)
|
84
|
+
end
|
85
|
+
|
86
|
+
def remove(options)
|
87
|
+
filename = options[:filename]
|
88
|
+
if !File.exist?(filename)
|
89
|
+
$stderr.puts "No #{filename} file exists yet. You can use the 'create' subcommand to create one."
|
90
|
+
exit 1
|
91
|
+
end
|
92
|
+
|
93
|
+
maintainers = JSON.load(File.read(filename))
|
94
|
+
index = maintainers["people"].index { |person| person["github"] == options[:github] }
|
95
|
+
if index
|
96
|
+
maintainers["people"].slice!(index)
|
97
|
+
else
|
98
|
+
puts "I didn't find #{options[:github]} in the file #{filename}"
|
99
|
+
end
|
100
|
+
|
101
|
+
write_file(filename, maintainers)
|
102
|
+
end
|
103
|
+
end
|
104
|
+
end
|
data/maintainers.gemspec
ADDED
@@ -0,0 +1,25 @@
|
|
1
|
+
# coding: utf-8
|
2
|
+
lib = File.expand_path('../lib', __FILE__)
|
3
|
+
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
4
|
+
require 'maintainers/version'
|
5
|
+
|
6
|
+
Gem::Specification.new do |spec|
|
7
|
+
spec.name = "maintainers"
|
8
|
+
spec.version = Maintainers::VERSION
|
9
|
+
spec.authors = ["Puppet, Inc"]
|
10
|
+
|
11
|
+
spec.summary = %q{A gem for maintaining MAINTAINERS files}
|
12
|
+
spec.homepage = "https://github.com/puppetlabs/maintainers"
|
13
|
+
|
14
|
+
spec.files = `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
|
15
|
+
spec.bindir = 'bin'
|
16
|
+
spec.executables << 'maintainers'
|
17
|
+
spec.require_paths = ['lib']
|
18
|
+
|
19
|
+
spec.add_development_dependency "bundler", "~> 1.12"
|
20
|
+
spec.add_development_dependency "rake", "~> 10.0"
|
21
|
+
spec.add_development_dependency "rspec", "~> 3.0"
|
22
|
+
spec.add_development_dependency "byebug", "~> 9.0"
|
23
|
+
|
24
|
+
spec.add_runtime_dependency 'json-schema', '~> 2.6'
|
25
|
+
end
|
@@ -0,0 +1,49 @@
|
|
1
|
+
{
|
2
|
+
"$schema": "http://json-schema.org/draft-04/schema#",
|
3
|
+
"title": "Maintainers file format",
|
4
|
+
"type": "object",
|
5
|
+
"additionalProperties": true,
|
6
|
+
"required": [ "version", "issues", "people" ],
|
7
|
+
"properties": {
|
8
|
+
"version": {
|
9
|
+
"description": "Version of this file format. Initially only: 1",
|
10
|
+
"type": "number",
|
11
|
+
"minimum": 1,
|
12
|
+
"maximum": 1
|
13
|
+
},
|
14
|
+
"issues": {
|
15
|
+
"description": "Where to file issues",
|
16
|
+
"type": "string"
|
17
|
+
},
|
18
|
+
"maintained": {
|
19
|
+
"description": "Is this repo maintained? Optional field, but set false to make clear that a repo is not maintained.",
|
20
|
+
"type": "boolean"
|
21
|
+
},
|
22
|
+
"people": {
|
23
|
+
"type": "array",
|
24
|
+
"items": {
|
25
|
+
"type": "object",
|
26
|
+
"additionalProperties": false,
|
27
|
+
"required": [ "github" ],
|
28
|
+
"properties": {
|
29
|
+
"github": {
|
30
|
+
"description": "The maintainer's github id. Note that this is the only requied field.",
|
31
|
+
"type": "string"
|
32
|
+
},
|
33
|
+
"email": {
|
34
|
+
"description": "The maintainer's email address. Optional, and if present, no format is enforced, so uses like 'fry at puppet' are fine.",
|
35
|
+
"type": "string"
|
36
|
+
},
|
37
|
+
"name": {
|
38
|
+
"description": "The maintainer's name. Optional.",
|
39
|
+
"type": "string"
|
40
|
+
},
|
41
|
+
"comment": {
|
42
|
+
"description": "Optional comment field. May be handy for identifying subsystem ownership or just general awesomeness.",
|
43
|
+
"type": "string"
|
44
|
+
}
|
45
|
+
}
|
46
|
+
}
|
47
|
+
}
|
48
|
+
}
|
49
|
+
}
|
@@ -0,0 +1,150 @@
|
|
1
|
+
{
|
2
|
+
"id": "http://json-schema.org/draft-04/schema#",
|
3
|
+
"$schema": "http://json-schema.org/draft-04/schema#",
|
4
|
+
"description": "Core schema meta-schema",
|
5
|
+
"definitions": {
|
6
|
+
"schemaArray": {
|
7
|
+
"type": "array",
|
8
|
+
"minItems": 1,
|
9
|
+
"items": { "$ref": "#" }
|
10
|
+
},
|
11
|
+
"positiveInteger": {
|
12
|
+
"type": "integer",
|
13
|
+
"minimum": 0
|
14
|
+
},
|
15
|
+
"positiveIntegerDefault0": {
|
16
|
+
"allOf": [ { "$ref": "#/definitions/positiveInteger" }, { "default": 0 } ]
|
17
|
+
},
|
18
|
+
"simpleTypes": {
|
19
|
+
"enum": [ "array", "boolean", "integer", "null", "number", "object", "string" ]
|
20
|
+
},
|
21
|
+
"stringArray": {
|
22
|
+
"type": "array",
|
23
|
+
"items": { "type": "string" },
|
24
|
+
"minItems": 1,
|
25
|
+
"uniqueItems": true
|
26
|
+
}
|
27
|
+
},
|
28
|
+
"type": "object",
|
29
|
+
"properties": {
|
30
|
+
"id": {
|
31
|
+
"type": "string",
|
32
|
+
"format": "uri"
|
33
|
+
},
|
34
|
+
"$schema": {
|
35
|
+
"type": "string",
|
36
|
+
"format": "uri"
|
37
|
+
},
|
38
|
+
"title": {
|
39
|
+
"type": "string"
|
40
|
+
},
|
41
|
+
"description": {
|
42
|
+
"type": "string"
|
43
|
+
},
|
44
|
+
"default": {},
|
45
|
+
"multipleOf": {
|
46
|
+
"type": "number",
|
47
|
+
"minimum": 0,
|
48
|
+
"exclusiveMinimum": true
|
49
|
+
},
|
50
|
+
"maximum": {
|
51
|
+
"type": "number"
|
52
|
+
},
|
53
|
+
"exclusiveMaximum": {
|
54
|
+
"type": "boolean",
|
55
|
+
"default": false
|
56
|
+
},
|
57
|
+
"minimum": {
|
58
|
+
"type": "number"
|
59
|
+
},
|
60
|
+
"exclusiveMinimum": {
|
61
|
+
"type": "boolean",
|
62
|
+
"default": false
|
63
|
+
},
|
64
|
+
"maxLength": { "$ref": "#/definitions/positiveInteger" },
|
65
|
+
"minLength": { "$ref": "#/definitions/positiveIntegerDefault0" },
|
66
|
+
"pattern": {
|
67
|
+
"type": "string",
|
68
|
+
"format": "regex"
|
69
|
+
},
|
70
|
+
"additionalItems": {
|
71
|
+
"anyOf": [
|
72
|
+
{ "type": "boolean" },
|
73
|
+
{ "$ref": "#" }
|
74
|
+
],
|
75
|
+
"default": {}
|
76
|
+
},
|
77
|
+
"items": {
|
78
|
+
"anyOf": [
|
79
|
+
{ "$ref": "#" },
|
80
|
+
{ "$ref": "#/definitions/schemaArray" }
|
81
|
+
],
|
82
|
+
"default": {}
|
83
|
+
},
|
84
|
+
"maxItems": { "$ref": "#/definitions/positiveInteger" },
|
85
|
+
"minItems": { "$ref": "#/definitions/positiveIntegerDefault0" },
|
86
|
+
"uniqueItems": {
|
87
|
+
"type": "boolean",
|
88
|
+
"default": false
|
89
|
+
},
|
90
|
+
"maxProperties": { "$ref": "#/definitions/positiveInteger" },
|
91
|
+
"minProperties": { "$ref": "#/definitions/positiveIntegerDefault0" },
|
92
|
+
"required": { "$ref": "#/definitions/stringArray" },
|
93
|
+
"additionalProperties": {
|
94
|
+
"anyOf": [
|
95
|
+
{ "type": "boolean" },
|
96
|
+
{ "$ref": "#" }
|
97
|
+
],
|
98
|
+
"default": {}
|
99
|
+
},
|
100
|
+
"definitions": {
|
101
|
+
"type": "object",
|
102
|
+
"additionalProperties": { "$ref": "#" },
|
103
|
+
"default": {}
|
104
|
+
},
|
105
|
+
"properties": {
|
106
|
+
"type": "object",
|
107
|
+
"additionalProperties": { "$ref": "#" },
|
108
|
+
"default": {}
|
109
|
+
},
|
110
|
+
"patternProperties": {
|
111
|
+
"type": "object",
|
112
|
+
"additionalProperties": { "$ref": "#" },
|
113
|
+
"default": {}
|
114
|
+
},
|
115
|
+
"dependencies": {
|
116
|
+
"type": "object",
|
117
|
+
"additionalProperties": {
|
118
|
+
"anyOf": [
|
119
|
+
{ "$ref": "#" },
|
120
|
+
{ "$ref": "#/definitions/stringArray" }
|
121
|
+
]
|
122
|
+
}
|
123
|
+
},
|
124
|
+
"enum": {
|
125
|
+
"type": "array",
|
126
|
+
"minItems": 1,
|
127
|
+
"uniqueItems": true
|
128
|
+
},
|
129
|
+
"type": {
|
130
|
+
"anyOf": [
|
131
|
+
{ "$ref": "#/definitions/simpleTypes" },
|
132
|
+
{
|
133
|
+
"type": "array",
|
134
|
+
"items": { "$ref": "#/definitions/simpleTypes" },
|
135
|
+
"minItems": 1,
|
136
|
+
"uniqueItems": true
|
137
|
+
}
|
138
|
+
]
|
139
|
+
},
|
140
|
+
"allOf": { "$ref": "#/definitions/schemaArray" },
|
141
|
+
"anyOf": { "$ref": "#/definitions/schemaArray" },
|
142
|
+
"oneOf": { "$ref": "#/definitions/schemaArray" },
|
143
|
+
"not": { "$ref": "#" }
|
144
|
+
},
|
145
|
+
"dependencies": {
|
146
|
+
"exclusiveMaximum": [ "maximum" ],
|
147
|
+
"exclusiveMinimum": [ "minimum" ]
|
148
|
+
},
|
149
|
+
"default": {}
|
150
|
+
}
|
metadata
ADDED
@@ -0,0 +1,134 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: maintainers
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.1.0
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Puppet, Inc
|
8
|
+
autorequire:
|
9
|
+
bindir: bin
|
10
|
+
cert_chain: []
|
11
|
+
date: 2016-09-01 00:00:00.000000000 Z
|
12
|
+
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: bundler
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - "~>"
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: '1.12'
|
20
|
+
type: :development
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - "~>"
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: '1.12'
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: rake
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - "~>"
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: '10.0'
|
34
|
+
type: :development
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - "~>"
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: '10.0'
|
41
|
+
- !ruby/object:Gem::Dependency
|
42
|
+
name: rspec
|
43
|
+
requirement: !ruby/object:Gem::Requirement
|
44
|
+
requirements:
|
45
|
+
- - "~>"
|
46
|
+
- !ruby/object:Gem::Version
|
47
|
+
version: '3.0'
|
48
|
+
type: :development
|
49
|
+
prerelease: false
|
50
|
+
version_requirements: !ruby/object:Gem::Requirement
|
51
|
+
requirements:
|
52
|
+
- - "~>"
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: '3.0'
|
55
|
+
- !ruby/object:Gem::Dependency
|
56
|
+
name: byebug
|
57
|
+
requirement: !ruby/object:Gem::Requirement
|
58
|
+
requirements:
|
59
|
+
- - "~>"
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: '9.0'
|
62
|
+
type: :development
|
63
|
+
prerelease: false
|
64
|
+
version_requirements: !ruby/object:Gem::Requirement
|
65
|
+
requirements:
|
66
|
+
- - "~>"
|
67
|
+
- !ruby/object:Gem::Version
|
68
|
+
version: '9.0'
|
69
|
+
- !ruby/object:Gem::Dependency
|
70
|
+
name: json-schema
|
71
|
+
requirement: !ruby/object:Gem::Requirement
|
72
|
+
requirements:
|
73
|
+
- - "~>"
|
74
|
+
- !ruby/object:Gem::Version
|
75
|
+
version: '2.6'
|
76
|
+
type: :runtime
|
77
|
+
prerelease: false
|
78
|
+
version_requirements: !ruby/object:Gem::Requirement
|
79
|
+
requirements:
|
80
|
+
- - "~>"
|
81
|
+
- !ruby/object:Gem::Version
|
82
|
+
version: '2.6'
|
83
|
+
description:
|
84
|
+
email:
|
85
|
+
executables:
|
86
|
+
- maintainers
|
87
|
+
extensions: []
|
88
|
+
extra_rdoc_files: []
|
89
|
+
files:
|
90
|
+
- ".gitignore"
|
91
|
+
- ".rspec"
|
92
|
+
- ".travis.yml"
|
93
|
+
- CHANGELOG
|
94
|
+
- CODE_OF_CONDUCT.md
|
95
|
+
- Gemfile
|
96
|
+
- LICENSE
|
97
|
+
- MAINTAINERS-example
|
98
|
+
- MAINTAINERS-unmaintained_example
|
99
|
+
- README.md
|
100
|
+
- Rakefile
|
101
|
+
- bin/console
|
102
|
+
- bin/maintainers
|
103
|
+
- bin/setup
|
104
|
+
- lib/maintainers.rb
|
105
|
+
- lib/maintainers/cli.rb
|
106
|
+
- lib/maintainers/runner.rb
|
107
|
+
- lib/maintainers/version.rb
|
108
|
+
- maintainers.gemspec
|
109
|
+
- schema/MAINTAINERS.json
|
110
|
+
- schema/json-meta-schema.json
|
111
|
+
homepage: https://github.com/puppetlabs/maintainers
|
112
|
+
licenses: []
|
113
|
+
metadata: {}
|
114
|
+
post_install_message:
|
115
|
+
rdoc_options: []
|
116
|
+
require_paths:
|
117
|
+
- lib
|
118
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
119
|
+
requirements:
|
120
|
+
- - ">="
|
121
|
+
- !ruby/object:Gem::Version
|
122
|
+
version: '0'
|
123
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
124
|
+
requirements:
|
125
|
+
- - ">="
|
126
|
+
- !ruby/object:Gem::Version
|
127
|
+
version: '0'
|
128
|
+
requirements: []
|
129
|
+
rubyforge_project:
|
130
|
+
rubygems_version: 2.5.1
|
131
|
+
signing_key:
|
132
|
+
specification_version: 4
|
133
|
+
summary: A gem for maintaining MAINTAINERS files
|
134
|
+
test_files: []
|