freshli-commons 0.6.0 → 0.6.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (5) hide show
  1. checksums.yaml +4 -4
  2. data/.semver +1 -1
  3. data/CODE_OF_CONDUCT.md +128 -0
  4. data/README.md +54 -9
  5. metadata +17 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: cc5d50a4b6a1a5df06c1d51cfcc180d8236fd15145b2a205f1d3d7209e78bdd6
4
- data.tar.gz: d2ad6c97040b1fddc3afb42d8d403b465a55a1d5c7c745f99570c5c8fa463d58
3
+ metadata.gz: d0441a6a6d0f50aabe59ba737953b8aede052fa3b05f38ec073224b35a47cdcf
4
+ data.tar.gz: 5918030bf753e13c56d915be06b2de14d0658fb246904be370681e5d5184f3d5
5
5
  SHA512:
6
- metadata.gz: 99e6d91119d93d7468377e2ac87fe6e88bff94471dd61c67617222879167b97af58bc22446eba1771c6e320c5414ab219b37a50910024b7cc11c0410f449a41e
7
- data.tar.gz: 56e37d6bc7ae6c825681fa1b884611f2a04faa86846a9e519610e322e27e4c2103aa87880d08e355fb80d9f840ffe30d5e1276d9cc3c2a3e74390b24b4931f80
6
+ metadata.gz: 31a2935147ee357fe9cc9bd371176649eb371161c5976eaeb5ee8f9002c3ec92d71ac8cb11b4c7684927127e9837530ce8e729fde73c2ad5b70ae64b4169ac5e
7
+ data.tar.gz: 8b735a2e8b99f484c289e9024b0a561e253dd425dbb639e56914103c7e98361c0d1b6cd0f84208062af2afe390bfbf7d747c7d89a0fd0ce6d28a4071906e47f6
data/.semver CHANGED
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  :major: 0
3
3
  :minor: 6
4
- :patch: 0
4
+ :patch: 1
5
5
  :special: ''
6
6
  :metadata: ''
@@ -0,0 +1,128 @@
1
+ # Contributor Covenant Code of Conduct
2
+
3
+ ## Our Pledge
4
+
5
+ We as members, contributors, and leaders pledge to make participation in our
6
+ community a harassment-free experience for everyone, regardless of age, body
7
+ size, visible or invisible disability, ethnicity, sex characteristics, gender
8
+ identity and expression, level of experience, education, socio-economic status,
9
+ nationality, personal appearance, race, religion, or sexual identity
10
+ and orientation.
11
+
12
+ We pledge to act and interact in ways that contribute to an open, welcoming,
13
+ diverse, inclusive, and healthy community.
14
+
15
+ ## Our Standards
16
+
17
+ Examples of behavior that contributes to a positive environment for our
18
+ community include:
19
+
20
+ * Demonstrating empathy and kindness toward other people
21
+ * Being respectful of differing opinions, viewpoints, and experiences
22
+ * Giving and gracefully accepting constructive feedback
23
+ * Accepting responsibility and apologizing to those affected by our mistakes,
24
+ and learning from the experience
25
+ * Focusing on what is best not just for us as individuals, but for the
26
+ overall community
27
+
28
+ Examples of unacceptable behavior include:
29
+
30
+ * The use of sexualized language or imagery, and sexual attention or
31
+ advances of any kind
32
+ * Trolling, insulting or derogatory comments, and personal or political attacks
33
+ * Public or private harassment
34
+ * Publishing others' private information, such as a physical or email
35
+ address, without their explicit permission
36
+ * Other conduct which could reasonably be considered inappropriate in a
37
+ professional setting
38
+
39
+ ## Enforcement Responsibilities
40
+
41
+ Community leaders are responsible for clarifying and enforcing our standards of
42
+ acceptable behavior and will take appropriate and fair corrective action in
43
+ response to any behavior that they deem inappropriate, threatening, offensive,
44
+ or harmful.
45
+
46
+ Community leaders have the right and responsibility to remove, edit, or reject
47
+ comments, commits, code, wiki edits, issues, and other contributions that are
48
+ not aligned to this Code of Conduct, and will communicate reasons for moderation
49
+ decisions when appropriate.
50
+
51
+ ## Scope
52
+
53
+ This Code of Conduct applies within all community spaces, and also applies when
54
+ an individual is officially representing the community in public spaces.
55
+ Examples of representing our community include using an official e-mail address,
56
+ posting via an official social media account, or acting as an appointed
57
+ representative at an online or offline event.
58
+
59
+ ## Enforcement
60
+
61
+ Instances of abusive, harassing, or otherwise unacceptable behavior may be
62
+ reported to the community leaders responsible for enforcement at
63
+ coc@freshli.io.
64
+ All complaints will be reviewed and investigated promptly and fairly.
65
+
66
+ All community leaders are obligated to respect the privacy and security of the
67
+ reporter of any incident.
68
+
69
+ ## Enforcement Guidelines
70
+
71
+ Community leaders will follow these Community Impact Guidelines in determining
72
+ the consequences for any action they deem in violation of this Code of Conduct:
73
+
74
+ ### 1. Correction
75
+
76
+ **Community Impact**: Use of inappropriate language or other behavior deemed
77
+ unprofessional or unwelcome in the community.
78
+
79
+ **Consequence**: A private, written warning from community leaders, providing
80
+ clarity around the nature of the violation and an explanation of why the
81
+ behavior was inappropriate. A public apology may be requested.
82
+
83
+ ### 2. Warning
84
+
85
+ **Community Impact**: A violation through a single incident or series
86
+ of actions.
87
+
88
+ **Consequence**: A warning with consequences for continued behavior. No
89
+ interaction with the people involved, including unsolicited interaction with
90
+ those enforcing the Code of Conduct, for a specified period of time. This
91
+ includes avoiding interactions in community spaces as well as external channels
92
+ like social media. Violating these terms may lead to a temporary or
93
+ permanent ban.
94
+
95
+ ### 3. Temporary Ban
96
+
97
+ **Community Impact**: A serious violation of community standards, including
98
+ sustained inappropriate behavior.
99
+
100
+ **Consequence**: A temporary ban from any sort of interaction or public
101
+ communication with the community for a specified period of time. No public or
102
+ private interaction with the people involved, including unsolicited interaction
103
+ with those enforcing the Code of Conduct, is allowed during this period.
104
+ Violating these terms may lead to a permanent ban.
105
+
106
+ ### 4. Permanent Ban
107
+
108
+ **Community Impact**: Demonstrating a pattern of violation of community
109
+ standards, including sustained inappropriate behavior, harassment of an
110
+ individual, or aggression toward or disparagement of classes of individuals.
111
+
112
+ **Consequence**: A permanent ban from any sort of public interaction within
113
+ the community.
114
+
115
+ ## Attribution
116
+
117
+ This Code of Conduct is adapted from the [Contributor Covenant][homepage],
118
+ version 2.0, available at
119
+ https://www.contributor-covenant.org/version/2/0/code_of_conduct.html.
120
+
121
+ Community Impact Guidelines were inspired by [Mozilla's code of conduct
122
+ enforcement ladder](https://github.com/mozilla/diversity).
123
+
124
+ [homepage]: https://www.contributor-covenant.org
125
+
126
+ For answers to common questions about this code of conduct, see the FAQ at
127
+ https://www.contributor-covenant.org/faq. Translations are available at
128
+ https://www.contributor-covenant.org/translations.
data/README.md CHANGED
@@ -1,30 +1,75 @@
1
1
  # Corgibytes::Freshli::Commons
2
2
 
3
- TODO: Delete this and the text below, and describe your gem
4
-
5
- Welcome to your new gem! In this directory, you'll find the files you need to be able to package up your Ruby library into a gem. Put your Ruby code in the file `lib/corgibytes/freshli/commons`. To experiment with that code, run `bin/console` for an interactive prompt.
3
+ Common testing and build tools code used by [Freshli](https://github.com/corgibytes/freshli) projects.
6
4
 
7
5
  ## Installation
8
6
 
9
- TODO: Replace `UPDATE_WITH_YOUR_GEM_NAME_PRIOR_TO_RELEASE_TO_RUBYGEMS_ORG` with your gem name right after releasing it to RubyGems.org. Please do not do it earlier due to security reasons. Alternatively, replace this section with instructions to install your gem from git if you don't plan to release to RubyGems.org.
10
-
11
7
  Install the gem and add to the application's Gemfile by executing:
12
8
 
13
- $ bundle add UPDATE_WITH_YOUR_GEM_NAME_PRIOR_TO_RELEASE_TO_RUBYGEMS_ORG
9
+ $ bundle add freshli-commons
14
10
 
15
11
  If bundler is not being used to manage dependencies, install the gem by executing:
16
12
 
17
- $ gem install UPDATE_WITH_YOUR_GEM_NAME_PRIOR_TO_RELEASE_TO_RUBYGEMS_ORG
13
+ $ gem install freshli-commons
18
14
 
19
15
  ## Usage
20
16
 
21
- TODO: Write usage instructions here
17
+ ### Step Definitions
18
+
19
+ The following step definitions, and supporting classes, are defined in this repository:
20
+
21
+ Working with command output:
22
+
23
+ * `Then(/^it should (pass|fail) with exact output containing file paths:$/)`
24
+
25
+ Working with CycloneDX files:
26
+
27
+ * `Then('the CycloneDX file {string} should be valid')`
28
+ * `Then('the CycloneDX file {string} should contain {string}')`
29
+
30
+ Working with Git repositories:
31
+
32
+ * `Given('I clone the git repository {string} with the sha {string}')`
33
+ * `Then('running git status should not report any modifications for {string}')`
34
+
35
+ Working with Freshli Language Agent gRPC services:
36
+
37
+ * `Given('a test service is started on port {int}')`
38
+ * `Then('GetValidatingRepositories response should contain:')`
39
+ * `Then('RetrieveReleaseHistory response should be empty')`
40
+ * `Then('RetrieveReleaseHistory response should contain the following versions and release dates:')`
41
+ * `Then('the DetectManifests response contains the following file paths expanded beneath {string}:')`
42
+ * `Then('the freshli_agent.proto gRPC service is running on port {int}')`
43
+ * `Then('the GetValidatingPackages response should contain:')`
44
+ * `Then('the ProcessManifest response contains the following file paths expanded beneath {string}:')`
45
+ * `Then('there are no services running on port {int}')`
46
+ * `When('I call DetectManifests with the full path to {string} on port {int}')`
47
+ * `When('I call GetValidatingPackages on port {int}')`
48
+ * `When('I call GetValidatingRepositories on port {int}')`
49
+ * `When('I call ProcessManifest with the expanded path {string} and the moment {string} on port {int}')`
50
+ * `When('I call RetrieveReleaseHistory with {string} on port {int}')`
51
+ * `When('I wait for the freshli_agent.proto gRPC service to be running on port {int}')`
52
+ * `When('the gRPC service on port {int} is sent the shutdown command')`
53
+ * `When('the test service running on port {int} is stopped')`
54
+
55
+ ### Execute
56
+
57
+ The `Corgibytes::Freshli::Commons::Execute` module contains methods for helping with executing shell commands in a shell/like Ruby script, such as `build.rb`, `test.rb`, `lint.rb`.
58
+
59
+ Files that use it should pull it in using:
60
+
61
+ require 'corgibytes/freshli/commons/execute'
62
+ # rubocop:disable Style/MixinUsage
63
+ include Corgibytes::Freshli::Commons::Execute
64
+ # rubocop:enable Style/MixinUsage
65
+
66
+ The `rubocop` disable/enable lines avoid a warning from Rubocop about including the modules contents into the global namespace.
22
67
 
23
68
  ## Development
24
69
 
25
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.
26
71
 
27
- 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 the created tag, and push the `.gem` file to [rubygems.org](https://rubygems.org).
72
+ To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `.semver`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and the created tag, and push the `.gem` file to [rubygems.org](https://rubygems.org).
28
73
 
29
74
  ## Contributing
30
75
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: freshli-commons
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.6.0
4
+ version: 0.6.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - M. Scott Ford
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2023-08-19 00:00:00.000000000 Z
11
+ date: 2023-08-25 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: aruba
@@ -38,6 +38,20 @@ dependencies:
38
38
  - - ">="
39
39
  - !ruby/object:Gem::Version
40
40
  version: '0'
41
+ - !ruby/object:Gem::Dependency
42
+ name: grpc-tools
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - ">="
46
+ - !ruby/object:Gem::Version
47
+ version: '0'
48
+ type: :runtime
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - ">="
53
+ - !ruby/object:Gem::Version
54
+ version: '0'
41
55
  - !ruby/object:Gem::Dependency
42
56
  name: rspec-expectations
43
57
  requirement: !ruby/object:Gem::Requirement
@@ -78,6 +92,7 @@ files:
78
92
  - ".rspec"
79
93
  - ".rubocop.yml"
80
94
  - ".semver"
95
+ - CODE_OF_CONDUCT.md
81
96
  - LICENSE
82
97
  - README.md
83
98
  - Rakefile