osrcry 0.2.3 → 0.3.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.lock +1 -1
- data/bin/osrcry +8 -7
- data/lib/osrcry.rb +5 -0
- data/lib/osrcry/code_of_conduct.rb +91 -0
- data/lib/osrcry/version.rb +1 -1
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: fab2396ec4513ee76950d4585c80134255aabfa0
|
4
|
+
data.tar.gz: 87f52a8beecd2e184ff42703afa0216e31a4db37
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ccffa665fd5b9808ec23bf5d9a1e2a85fa70b8d849486eed1654068a7ed5e7d675e418c77164c71c96f163abc474b71b1ec62ff039ca43a010a195ed4c9b7a62
|
7
|
+
data.tar.gz: 13ac9b34c31bdbf0d199930e1240669b277505ab81dfe456b4d2a727c0fa733ba56af9826fcd902fed8a5b894600c662a24456f1c59d0e55e20950a8696e1844
|
data/Gemfile.lock
CHANGED
data/bin/osrcry
CHANGED
@@ -2,15 +2,13 @@
|
|
2
2
|
|
3
3
|
require File.expand_path(File.join(File.dirname(__FILE__), '..', 'lib', 'osrcry'))
|
4
4
|
|
5
|
-
arguments = ARGV.map {|arg| arg.downcase}
|
5
|
+
arguments = ARGV.map {|arg| arg.downcase.split('.md', 2).first}
|
6
6
|
commands = %w{
|
7
|
+
code_of_conduct
|
7
8
|
contributing
|
8
|
-
contributing.md
|
9
9
|
contributors
|
10
|
-
contributors.md
|
11
10
|
init
|
12
11
|
license
|
13
|
-
license.md
|
14
12
|
stale
|
15
13
|
}
|
16
14
|
|
@@ -19,15 +17,18 @@ unless arguments.any? {|argument| commands.include?(argument)}
|
|
19
17
|
else
|
20
18
|
arguments.each do |command|
|
21
19
|
case command
|
22
|
-
when '
|
20
|
+
when 'code_of_conduct'
|
23
21
|
Osrcry::Contributing.execute
|
24
|
-
when '
|
22
|
+
when 'contributing'
|
23
|
+
Osrcry::Contributing.execute
|
24
|
+
when 'contributors'
|
25
25
|
Osrcry::Contributors.execute
|
26
26
|
when 'init'
|
27
|
+
Osrcry::CodeOfConduct.execute
|
27
28
|
Osrcry::Contributing.execute
|
28
29
|
Osrcry::Contributors.execute
|
29
30
|
Osrcry::License.execute
|
30
|
-
when 'license'
|
31
|
+
when 'license'
|
31
32
|
Osrcry::License.execute
|
32
33
|
when 'stale'
|
33
34
|
Osrcry::Stale.execute
|
data/lib/osrcry.rb
CHANGED
@@ -1,4 +1,5 @@
|
|
1
1
|
dir = File.dirname(__FILE__)
|
2
|
+
require File.join(dir, 'osrcry', 'code_of_conduct')
|
2
3
|
require File.join(dir, 'osrcry', 'contributing')
|
3
4
|
require File.join(dir, 'osrcry', 'contributors')
|
4
5
|
require File.join(dir, 'osrcry', 'license')
|
@@ -7,6 +8,10 @@ require File.join(dir, 'osrcry', 'version')
|
|
7
8
|
|
8
9
|
module Osrcry
|
9
10
|
|
11
|
+
def self.email
|
12
|
+
@email ||= ENV['OSRCRY_EMAIL'] || `git config user.email`
|
13
|
+
end
|
14
|
+
|
10
15
|
def self.remote
|
11
16
|
@remote ||= `git remote -v`.split("\n").detect {|line| line =~ /^origin/}
|
12
17
|
end
|
@@ -0,0 +1,91 @@
|
|
1
|
+
module Osrcry
|
2
|
+
class License
|
3
|
+
def self.execute
|
4
|
+
unless Osrcry.email
|
5
|
+
puts "Unable to create CODE_OF_CONDUCT.md due to missing email.\nPlease set ENV['OSRCRY_EMAIL'] or add git config user.email and try again."
|
6
|
+
return
|
7
|
+
end
|
8
|
+
|
9
|
+
code_of_conduct = <<-CODEOFCONDUCT
|
10
|
+
# Contributor Covenant Code of Conduct
|
11
|
+
|
12
|
+
## Our Pledge
|
13
|
+
|
14
|
+
In the interest of fostering an open and welcoming environment, we as
|
15
|
+
contributors and maintainers pledge to making participation in our project and
|
16
|
+
our community a harassment-free experience for everyone, regardless of age, body
|
17
|
+
size, disability, ethnicity, gender identity and expression, level of experience,
|
18
|
+
nationality, personal appearance, race, religion, or sexual identity and
|
19
|
+
orientation.
|
20
|
+
|
21
|
+
## Our Standards
|
22
|
+
|
23
|
+
Examples of behavior that contributes to creating a positive environment
|
24
|
+
include:
|
25
|
+
|
26
|
+
* Using welcoming and inclusive language
|
27
|
+
* Being respectful of differing viewpoints and experiences
|
28
|
+
* Gracefully accepting constructive criticism
|
29
|
+
* Focusing on what is best for the community
|
30
|
+
* Showing empathy towards other community members
|
31
|
+
|
32
|
+
Examples of unacceptable behavior by participants include:
|
33
|
+
|
34
|
+
* The use of sexualized language or imagery and unwelcome sexual attention or
|
35
|
+
advances
|
36
|
+
* Trolling, insulting/derogatory comments, and personal or political attacks
|
37
|
+
* Public or private harassment
|
38
|
+
* Publishing others' private information, such as a physical or electronic
|
39
|
+
address, without explicit permission
|
40
|
+
* Other conduct which could reasonably be considered inappropriate in a
|
41
|
+
professional setting
|
42
|
+
|
43
|
+
## Our Responsibilities
|
44
|
+
|
45
|
+
Project maintainers are responsible for clarifying the standards of acceptable
|
46
|
+
behavior and are expected to take appropriate and fair corrective action in
|
47
|
+
response to any instances of unacceptable behavior.
|
48
|
+
|
49
|
+
Project maintainers have the right and responsibility to remove, edit, or
|
50
|
+
reject comments, commits, code, wiki edits, issues, and other contributions
|
51
|
+
that are not aligned to this Code of Conduct, or to ban temporarily or
|
52
|
+
permanently any contributor for other behaviors that they deem inappropriate,
|
53
|
+
threatening, offensive, or harmful.
|
54
|
+
|
55
|
+
## Scope
|
56
|
+
|
57
|
+
This Code of Conduct applies both within project spaces and in public spaces
|
58
|
+
when an individual is representing the project or its community. Examples of
|
59
|
+
representing a project or community include using an official project e-mail
|
60
|
+
address, posting via an official social media account, or acting as an appointed
|
61
|
+
representative at an online or offline event. Representation of a project may be
|
62
|
+
further defined and clarified by project maintainers.
|
63
|
+
|
64
|
+
## Enforcement
|
65
|
+
|
66
|
+
Instances of abusive, harassing, or otherwise unacceptable behavior may be
|
67
|
+
reported by contacting the project team at #{Osrcry.email}. All
|
68
|
+
complaints will be reviewed and investigated and will result in a response that
|
69
|
+
is deemed necessary and appropriate to the circumstances. The project team is
|
70
|
+
obligated to maintain confidentiality with regard to the reporter of an incident.
|
71
|
+
Further details of specific enforcement policies may be posted separately.
|
72
|
+
|
73
|
+
Project maintainers who do not follow or enforce the Code of Conduct in good
|
74
|
+
faith may face temporary or permanent repercussions as determined by other
|
75
|
+
members of the project's leadership.
|
76
|
+
|
77
|
+
## Attribution
|
78
|
+
|
79
|
+
This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4,
|
80
|
+
available at [http://contributor-covenant.org/version/1/4][version]
|
81
|
+
|
82
|
+
[homepage]: http://contributor-covenant.org
|
83
|
+
[version]: http://contributor-covenant.org/version/1/4/
|
84
|
+
CODEOFCONDUCT
|
85
|
+
|
86
|
+
File.open('CODE_OF_CONDUCT.md', 'w') do |file|
|
87
|
+
file.write(code_of_conduct)
|
88
|
+
end
|
89
|
+
end
|
90
|
+
end
|
91
|
+
end
|
data/lib/osrcry/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: osrcry
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.3.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- geemus
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-
|
11
|
+
date: 2017-06-24 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -56,6 +56,7 @@ files:
|
|
56
56
|
- Rakefile
|
57
57
|
- bin/osrcry
|
58
58
|
- lib/osrcry.rb
|
59
|
+
- lib/osrcry/code_of_conduct.rb
|
59
60
|
- lib/osrcry/contributing.rb
|
60
61
|
- lib/osrcry/contributors.rb
|
61
62
|
- lib/osrcry/license.rb
|