way_of_working 2.0.1 → 2.2.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 +4 -4
- data/CHANGELOG.md +41 -1
- data/CLAUDE.md +48 -0
- data/CODE_OF_CONDUCT.md +55 -104
- data/CONTRIBUTING.md +62 -0
- data/README.md +240 -23
- data/exe/way_of_working +6 -1
- data/lib/way_of_working/audit/github/auditor.rb +47 -0
- data/lib/way_of_working/audit/github/generators/exec.rb +214 -0
- data/lib/way_of_working/audit/github/rules/base.rb +116 -0
- data/lib/way_of_working/audit/github/rules/registry.rb +44 -0
- data/lib/way_of_working/audit/github/rules/unknown.rb +19 -0
- data/lib/way_of_working/audit/github.rb +25 -0
- data/lib/way_of_working/changelog/keepachangelog/generators/init.rb +118 -0
- data/lib/way_of_working/changelog/keepachangelog/github_audit_rule.rb +32 -0
- data/lib/way_of_working/changelog/keepachangelog/templates/docs/way_of_working/changelog.md +73 -0
- data/lib/way_of_working/changelog/keepachangelog.rb +31 -0
- data/lib/way_of_working/cli.rb +13 -0
- data/lib/way_of_working/code_of_conduct/contributor_covenant/generators/init.rb +69 -0
- data/lib/way_of_working/code_of_conduct/contributor_covenant/github_audit_rule.rb +33 -0
- data/lib/way_of_working/code_of_conduct/contributor_covenant/templates/CODE_OF_CONDUCT.md.tt +83 -0
- data/lib/way_of_working/code_of_conduct/contributor_covenant/templates/docs/way_of_working/code-of-conduct.md +79 -0
- data/lib/way_of_working/code_of_conduct/contributor_covenant.rb +32 -0
- data/lib/way_of_working/completion.rb +60 -0
- data/lib/way_of_working/config.rb +45 -0
- data/lib/way_of_working/decision_record/madr/generators/init.rb +41 -0
- data/lib/way_of_working/decision_record/madr/generators/new.rb +69 -0
- data/lib/way_of_working/decision_record/madr/github_audit_rule.rb +37 -0
- data/lib/way_of_working/decision_record/madr/templates/.github/ISSUE_TEMPLATE/decision-record.md +26 -0
- data/lib/way_of_working/decision_record/madr/templates/docs/decisions/0000-use-markdown-any-decision-records.md +30 -0
- data/lib/way_of_working/decision_record/madr/templates/docs/decisions/README.md +7 -0
- data/lib/way_of_working/decision_record/madr/templates/docs/decisions/adr-template.md.tt +82 -0
- data/lib/way_of_working/decision_record/madr/templates/docs/decisions/index.md +48 -0
- data/lib/way_of_working/decision_record/madr/templates/docs/way_of_working/decision-records.md +195 -0
- data/lib/way_of_working/decision_record/madr.rb +49 -0
- data/lib/way_of_working/git/repo_reader.rb +2 -2
- data/lib/way_of_working/inclusive_language/alex/generators/exec.rb +51 -0
- data/lib/way_of_working/inclusive_language/alex/generators/init.rb +59 -0
- data/lib/way_of_working/inclusive_language/alex/github_audit_rule.rb +42 -0
- data/lib/way_of_working/inclusive_language/alex/templates/.alexignore +2 -0
- data/lib/way_of_working/inclusive_language/alex/templates/.alexrc +3 -0
- data/lib/way_of_working/inclusive_language/alex/templates/.github/workflows/inclusive-language.yml +16 -0
- data/lib/way_of_working/inclusive_language/alex/templates/docs/way_of_working/inclusive-language.md +28 -0
- data/lib/way_of_working/inclusive_language/alex.rb +46 -0
- data/lib/way_of_working/pull_request_template/hdi/generators/init.rb +26 -0
- data/lib/way_of_working/pull_request_template/hdi/github_audit_rule.rb +32 -0
- data/lib/way_of_working/pull_request_template/hdi/templates/.github/pull_request_template.md +51 -0
- data/lib/way_of_working/pull_request_template/hdi/templates/docs/way_of_working/pull-request-template-and-guidelines.md +50 -0
- data/lib/way_of_working/pull_request_template/hdi.rb +31 -0
- data/lib/way_of_working/readme_badge/generators/init.rb +11 -1
- data/lib/way_of_working/readme_badge/paths.rb +5 -2
- data/lib/way_of_working/readme_badge.rb +2 -6
- data/lib/way_of_working/sub_commands/base.rb +12 -0
- data/lib/way_of_working/sub_commands/config.rb +25 -0
- data/lib/way_of_working/sub_commands/init.rb +1 -1
- data/lib/way_of_working/version.rb +1 -1
- data/lib/way_of_working/versioning/semver/generators/init.rb +20 -0
- data/lib/way_of_working/versioning/semver/github_audit_rule.rb +38 -0
- data/lib/way_of_working/versioning/semver/templates/docs/way_of_working/versioning.md +71 -0
- data/lib/way_of_working/versioning/semver.rb +31 -0
- data/lib/way_of_working.rb +22 -0
- data/way_of_working.gemspec +5 -1
- metadata +108 -9
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: e80c5de893433da7e31dbdbf63240fd0cc2fba4fbdf4a5ca95d4402537273487
|
|
4
|
+
data.tar.gz: ae9e09728422fefbd4ca909dc59fae0032b7508b8aa1a2548c781c6ace3d8ffb
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 4ae36d59c5b5f8aaa715b240b3b47974f8d34d4cde064748e6fd158e6d411050989446626d0a377e14ffe66ef6c0dd25364430be8fbc57855c013204a9785833
|
|
7
|
+
data.tar.gz: 6af4793bf00e9bb706008b1f3d7d9d000b2cd4f5ecf9a17bfc6703dc80b5fde37b4cf53adf7464192cecf108c9a8b7e817c666e013563c1328d4a2178e1c9f4d
|
data/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
<!-- markdownlint-disable-file MD024 -->
|
|
1
2
|
# Changelog
|
|
2
3
|
|
|
3
4
|
All notable changes to this project will be documented in this file.
|
|
@@ -7,6 +8,43 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
7
8
|
|
|
8
9
|
## [Unreleased]
|
|
9
10
|
|
|
11
|
+
## [2.2.0] - 2026-11-25
|
|
12
|
+
|
|
13
|
+
### Added
|
|
14
|
+
|
|
15
|
+
- **CLI:** added bash and zsh Tab completion of commands and options, including those from plugins. Enable it with `eval "$(way_of_working completion zsh)"` (or `bash`).
|
|
16
|
+
- **GitHub Audit:** added `--rule` and `--tag` to run (and `--fix`) only the named audit rules or rules with a given tag, e.g. `--rule versioning/semver` or `--tag cis_level1`, and `--list-rules` to list the rule IDs and tags. Each audit result line now shows its rule ID, e.g. `Passed Semantic Versioning (versioning/semver)`. Plugins can give their rules shorter IDs by overriding `Rules::Base.rule_id`.
|
|
17
|
+
- **Config:** added `way_of_working config get`/`set` for persisting values (e.g. the Code of Conduct contact method) in `~/.config/way_of_working/config.yaml`, namespaced by dotted feature keys. `--contact-method` now falls back to the stored value and offers to remember a newly-provided one.
|
|
18
|
+
- **Inclusive Language:** `way_of_working init inclusive_language` now adds its GitHub Actions status badge to the README badge panel (created by `init readme_badge`) when the project has a GitHub remote.
|
|
19
|
+
|
|
20
|
+
### Changed
|
|
21
|
+
|
|
22
|
+
- **Inclusive Language:** the GitHub audit rule now checks that the workflow, `.alexignore`, `.alexrc` and documentation files match the templates, instead of only checking for a workflow named "Inclusive Language".
|
|
23
|
+
- **Code of Conduct:** upgraded Contributor Covenant 2.1 → 3 in place; `code_of_conduct/contributor_covenant` now generates v3 and v2.1 is no longer available. The GitHub audit rule now fails repos still on an older version.
|
|
24
|
+
|
|
25
|
+
### Fixed
|
|
26
|
+
|
|
27
|
+
- **README Badge:** rerunning `way_of_working init readme_badge` after the badge version or name changes (e.g. after upgrading the gem) now updates the existing badge instead of adding another badge holder to the README.
|
|
28
|
+
- **Audit:** built-in GitHub audit rules are no longer loaded inside `rescue LoadError`, so a rule that fails to load (e.g. a missing dependency) now raises instead of silently disappearing from the audit. `base64` is now a declared dependency.
|
|
29
|
+
- **CLI:** errors such as an unknown command now exit with status 1 instead of 0, and no longer print a Thor deprecation warning. Scripts that relied on a 0 exit status after an error will now see the failure.
|
|
30
|
+
- **CLI:** every command now starts about 0.2s faster: Octokit and the full set of ActiveSupport core extensions are loaded only when the GitHub audit runs, not whenever `way_of_working` is required.
|
|
31
|
+
- **Gem:** the gemspec homepage now points to the README on GitHub instead of the HDI-specific GitHub Pages site.
|
|
32
|
+
- **CLI:** `--help` now lists the options of generator commands, e.g. `way_of_working exec audit_github --help` shows `--all`, `--fix`, `--name`, `--public` and `--topic`.
|
|
33
|
+
- **Zeitwerk:** eager loading (e.g. a Rails app in production) no longer enables the opt-in built-in features or registers their GitHub audit rules; they now load only when explicitly required.
|
|
34
|
+
|
|
35
|
+
## [2.1.0] - 2026-06-08
|
|
36
|
+
|
|
37
|
+
### Added
|
|
38
|
+
|
|
39
|
+
- **Audit:** bundled the GitHub audit feature into this gem. It is opt in and replaces the separate `way_of_working-audit-github` plugin gem.
|
|
40
|
+
- **Changelog:** bundled the Keep a Changelog feature into this gem. It is opt in and replaces the separate `way_of_working-changelog-keepachangelog` plugin gem.
|
|
41
|
+
- **Code of Conduct:** bundled the Contributor Covenant feature into this gem. It is opt in and replaces the separate `way_of_working-code_of_conduct-contributor_covenant` plugin gem.
|
|
42
|
+
- **Decision Records:** bundled the MADR feature into this gem. It is opt in and replaces the separate `way_of_working-decision_record-madr` plugin gem.
|
|
43
|
+
- **Inclusive Language:** bundled the alex feature into this gem. It is opt in and replaces the separate `way_of_working-inclusive_language-alex` plugin gem.
|
|
44
|
+
- **Pull Request Template:** bundled the HDI feature into this gem. It is opt in and replaces the separate `way_of_working-pull_request_template-hdi` plugin gem.
|
|
45
|
+
- **Versioning:** bundled the Semantic Versioning feature into this gem. It is opt in and replaces the separate `way_of_working-versioning-semver` plugin gem.
|
|
46
|
+
- **Versioning:** documented the versioning policy in [ADR-0001](docs/decisions/0001-version-the-gem-interface-not-generated-content.md) and `CONTRIBUTING.md` — SemVer governs the gem's interface, not generated content; standard refreshes are minor, and drastic upgrades ship as additive variants.
|
|
47
|
+
|
|
10
48
|
## [2.0.1] - 2025-01-17
|
|
11
49
|
|
|
12
50
|
### Removed
|
|
@@ -61,7 +99,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
61
99
|
|
|
62
100
|
- Corrected use of relative paths in the rubocop config file
|
|
63
101
|
|
|
64
|
-
[unreleased]: https://github.com/HealthDataInsight/way_of_working/compare/v2.0
|
|
102
|
+
[unreleased]: https://github.com/HealthDataInsight/way_of_working/compare/v2.2.0...HEAD
|
|
103
|
+
[2.2.0]: https://github.com/HealthDataInsight/way_of_working/compare/v2.1.0...v2.2.0
|
|
104
|
+
[2.1.0]: https://github.com/HealthDataInsight/way_of_working/compare/v2.0.1...v2.1.0
|
|
65
105
|
[2.0.1]: https://github.com/HealthDataInsight/way_of_working/compare/v2.0.0...v2.0.1
|
|
66
106
|
[2.0.0]: https://github.com/HealthDataInsight/way_of_working/compare/v1.0.0...v2.0.0
|
|
67
107
|
[1.0.0]: https://github.com/HealthDataInsight/way_of_working/releases/tag/v1.0.0
|
data/CLAUDE.md
ADDED
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
# CLAUDE.md
|
|
2
|
+
|
|
3
|
+
## Commands
|
|
4
|
+
|
|
5
|
+
- `bin/setup` to install dependencies
|
|
6
|
+
- `bundle exec rake test` to run all tests
|
|
7
|
+
- `bundle exec ruby -Ilib -Itest test/way_of_working/decision_record/madr/generators/init_test.rb` to test one file
|
|
8
|
+
- `bundle exec ruby -Ilib -Itest test/path/to/file_test.rb -n "/files_are_created/"` to run on one test (names use underscores)
|
|
9
|
+
- `bundle exec rake rubocop` to lint Ruby
|
|
10
|
+
- `bundle exec exe/way_of_working help` to run the CLI from source
|
|
11
|
+
|
|
12
|
+
## Architecture
|
|
13
|
+
|
|
14
|
+
`way_of_working` is a Thor CLI (`exe/way_of_working` → `WayOfWorking::Cli`) with four subcommands: `init`, `new`, `exec` and `config`. Each is a `Thor` class in `lib/way_of_working/sub_commands/`.
|
|
15
|
+
Features add commands by reopening those classes and calling `register(GeneratorClass, name, usage, long_desc)`. `SubCommands::Base.register` copies a `Thor::Group`'s `class_options` onto the wrapper command so they show in `--help`.
|
|
16
|
+
|
|
17
|
+
**Features** follow a `category/variant` namespace (`decision_record/madr`, `code_of_conduct/contributor_covenant`). Each has:
|
|
18
|
+
|
|
19
|
+
- `<variant>.rb`: requires its generators, registers them with the subcommands and requires its audit rule unguarded, so a broken rule fails loudly.
|
|
20
|
+
- `<variant>/generators/*.rb`: `Thor::Group` + `Thor::Actions` generators whose `source_root` is `<variant>/templates/`. The templates mirror the target project's layout, and files ending `.tt` are ERB templates.
|
|
21
|
+
- `<variant>/github_audit_rule.rb`: a `Audit::Github::Rules::Base` subclass that registers itself with `Audit::Github::Rules::Registry`. It usually checks that the target repo contains the feature's template files verbatim.
|
|
22
|
+
|
|
23
|
+
**Opt-in loading:** `require 'way_of_working'` loads only `readme_badge`. Every other built-in feature (including `audit/github`) is enabled with an explicit `require 'way_of_working/<category>/<variant>'`. External plugins are gems named `way_of_working-*`, and `lib/way_of_working.rb` auto-requires their `<name with / for ->/plugin.rb`.
|
|
24
|
+
|
|
25
|
+
**Zeitwerk:** the gem uses `Zeitwerk::Loader.for_gem`, so file paths must match constant names. `lib/way_of_working.rb` ignores every `github_audit_rule.rb` with a glob, because those files register themselves on load and are required explicitly by their feature.
|
|
26
|
+
`zeitwerk_gem_loader_test.rb` and `zeitwerk_test_loader_test.rb` eager-load `lib/` and `test/` to enforce this. That means test files must declare the constant their path implies.
|
|
27
|
+
|
|
28
|
+
**Config:** `WayOfWorking::Config` stores values the user chooses to keep in `~/.config/way_of_working/config.yaml` (or under `$XDG_CONFIG_HOME`). Keys are namespaced by feature (`code_of_conduct.contact_method`).
|
|
29
|
+
A generator falls back to the stored value when an option isn't passed and offers to save new values (see `contributor_covenant/generators/init.rb`). `WayOfWorking::Configuration` is something else: organisation gems set the badge name and version there.
|
|
30
|
+
|
|
31
|
+
## Tests
|
|
32
|
+
|
|
33
|
+
The tests are Minitest with ActiveSupport and mocha. Generator tests subclass `Rails::Generators::TestCase` and write into `tmp/generators`. They usually check both `run_generator` and `run_generator [], behavior: :revoke`. Audit rule tests stub the Octokit client with mocha.
|
|
34
|
+
|
|
35
|
+
## Versioning and changelog
|
|
36
|
+
|
|
37
|
+
SemVer covers the gem's **interface**: CLI commands and options, feature require paths, and the plugin registration API. It doesn't cover generated content ([ADR-0001](docs/decisions/0001-version-the-gem-interface-not-generated-content.md)).
|
|
38
|
+
|
|
39
|
+
- Refreshing an embedded standard or adding a feature or variant is **MINOR**. A generation bug fix is **PATCH**. Breaking the interface is **MAJOR**.
|
|
40
|
+
- If a standard upgrade is drastic enough to surprise existing users, add a **new variant** next to the existing one instead of changing it.
|
|
41
|
+
- `CHANGELOG.md` follows Keep a Changelog. Add entries under `[Unreleased]` with a bold feature prefix, e.g. `- **Code of Conduct:** …`.
|
|
42
|
+
- Release by bumping `lib/way_of_working/version.rb`, moving the `[Unreleased]` entries under the new version, then running `bundle exec rake release`.
|
|
43
|
+
|
|
44
|
+
The repo uses its own generators: `docs/decisions/` and `docs/way_of_working/` are generated output, and the source templates live under `lib/**/templates/`.
|
|
45
|
+
|
|
46
|
+
## Pull requests
|
|
47
|
+
|
|
48
|
+
Write PR descriptions using the sections in `.github/pull_request_template.md` (What, Why, How, Testing, optional Screenshots, Anything Else).
|
data/CODE_OF_CONDUCT.md
CHANGED
|
@@ -1,133 +1,84 @@
|
|
|
1
1
|
<!--alex disable sex sexual-->
|
|
2
|
-
# Contributor Covenant Code of Conduct
|
|
2
|
+
# Contributor Covenant 3.0 Code of Conduct
|
|
3
3
|
|
|
4
4
|
## Our Pledge
|
|
5
5
|
|
|
6
|
-
We
|
|
7
|
-
community a harassment-free experience for everyone, regardless of age, body
|
|
8
|
-
size, visible or invisible disability, ethnicity, sex characteristics, gender
|
|
9
|
-
identity and expression, level of experience, education, socio-economic status,
|
|
10
|
-
nationality, personal appearance, race, caste, color, religion, or sexual
|
|
11
|
-
identity and orientation.
|
|
6
|
+
We pledge to make our community welcoming, safe, and equitable for all.
|
|
12
7
|
|
|
13
|
-
We
|
|
14
|
-
diverse, inclusive, and healthy community.
|
|
8
|
+
We are committed to fostering an environment that respects and promotes the dignity, rights, and contributions of all individuals, regardless of characteristics including race, ethnicity, caste, color, age, physical characteristics, neurodiversity, disability, sex or gender, gender identity or expression, sexual orientation, language, philosophy or religion, national or social origin, socio-economic position, level of education, or other status. The same privileges of participation are extended to everyone who participates in good faith and in accordance with this Covenant.
|
|
15
9
|
|
|
16
|
-
##
|
|
10
|
+
## Encouraged Behaviors
|
|
17
11
|
|
|
18
|
-
|
|
19
|
-
community include:
|
|
12
|
+
While acknowledging differences in social norms, we all strive to meet our community's expectations for positive behavior. We also understand that our words and actions may be interpreted differently than we intend based on culture, background, or native language.
|
|
20
13
|
|
|
21
|
-
|
|
22
|
-
* Being respectful of differing opinions, viewpoints, and experiences
|
|
23
|
-
* Giving and gracefully accepting constructive feedback
|
|
24
|
-
* Accepting responsibility and apologizing to those affected by our mistakes,
|
|
25
|
-
and learning from the experience
|
|
26
|
-
* Focusing on what is best not only for us as individuals, but for the overall
|
|
27
|
-
community
|
|
14
|
+
With these considerations in mind, we agree to behave mindfully toward each other and act in ways that center our shared values, including:
|
|
28
15
|
|
|
29
|
-
|
|
16
|
+
1. Respecting the **purpose of our community**, our activities, and our ways of gathering.
|
|
17
|
+
2. Engaging **kindly and honestly** with others.
|
|
18
|
+
3. Respecting **different viewpoints** and experiences.
|
|
19
|
+
4. **Taking responsibility** for our actions and contributions.
|
|
20
|
+
5. Gracefully giving and accepting **constructive feedback**.
|
|
21
|
+
6. Committing to **repairing harm** when it occurs.
|
|
22
|
+
7. Behaving in other ways that promote and sustain the **well-being of our community**.
|
|
30
23
|
|
|
31
|
-
|
|
32
|
-
any kind
|
|
33
|
-
* Trolling, insulting or derogatory comments, and personal or political attacks
|
|
34
|
-
* Public or private harassment
|
|
35
|
-
* Publishing others' private information, such as a physical or email address,
|
|
36
|
-
without their explicit permission
|
|
37
|
-
* Other conduct which could reasonably be considered inappropriate in a
|
|
38
|
-
professional setting
|
|
24
|
+
## Restricted Behaviors
|
|
39
25
|
|
|
40
|
-
|
|
26
|
+
We agree to restrict the following behaviors in our community. Instances, threats, and promotion of these behaviors are violations of this Code of Conduct.
|
|
41
27
|
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
or
|
|
28
|
+
1. **Harassment.** Violating explicitly expressed boundaries or engaging in unnecessary personal attention after any clear request to stop.
|
|
29
|
+
2. **Character attacks.** Making insulting, demeaning, or pejorative comments directed at a community member or group of people.
|
|
30
|
+
3. **Stereotyping or discrimination.** Characterizing anyone’s personality or behavior on the basis of immutable identities or traits.
|
|
31
|
+
4. **Sexualization.** Behaving in a way that would generally be considered inappropriately intimate in the context or purpose of the community.
|
|
32
|
+
5. **Violating confidentiality**. Sharing or acting on someone's personal or private information without their permission.
|
|
33
|
+
6. **Endangerment.** Causing, encouraging, or threatening violence or other harm toward any person or group.
|
|
34
|
+
7. Behaving in other ways that **threaten the well-being** of our community.
|
|
46
35
|
|
|
47
|
-
|
|
48
|
-
comments, commits, code, wiki edits, issues, and other contributions that are
|
|
49
|
-
not aligned to this Code of Conduct, and will communicate reasons for moderation
|
|
50
|
-
decisions when appropriate.
|
|
36
|
+
### Other Restrictions
|
|
51
37
|
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
Examples of representing our community include using an official e-mail address,
|
|
57
|
-
posting via an official social media account, or acting as an appointed
|
|
58
|
-
representative at an online or offline event.
|
|
59
|
-
|
|
60
|
-
## Enforcement
|
|
61
|
-
|
|
62
|
-
Instances of abusive, harassing, or otherwise unacceptable behavior may be
|
|
63
|
-
reported to the community leaders responsible for enforcement at
|
|
64
|
-
report.complaints@healthdatainsight.org.uk.
|
|
65
|
-
All complaints will be reviewed and investigated promptly and fairly.
|
|
66
|
-
|
|
67
|
-
All community leaders are obligated to respect the privacy and security of the
|
|
68
|
-
reporter of any incident.
|
|
69
|
-
|
|
70
|
-
## Enforcement Guidelines
|
|
38
|
+
1. **Misleading identity.** Impersonating someone else for any reason, or pretending to be someone else to evade enforcement actions.
|
|
39
|
+
2. **Failing to credit sources.** Not properly crediting the sources of content you contribute.
|
|
40
|
+
3. **Promotional materials**. Sharing marketing or other commercial content in a way that is outside the norms of the community.
|
|
41
|
+
4. **Irresponsible communication.** Failing to responsibly present content which includes, links or describes any other restricted behaviors.
|
|
71
42
|
|
|
72
|
-
|
|
73
|
-
the consequences for any action they deem in violation of this Code of Conduct:
|
|
43
|
+
## Reporting an Issue
|
|
74
44
|
|
|
75
|
-
|
|
45
|
+
Tensions can occur between community members even when they are trying their best to collaborate. Not every conflict represents a code of conduct violation, and this Code of Conduct reinforces encouraged behaviors and norms that can help avoid conflicts and minimize harm.
|
|
76
46
|
|
|
77
|
-
|
|
78
|
-
unprofessional or unwelcome in the community.
|
|
47
|
+
When an incident does occur, it is important to report it promptly. To report a possible violation, contact the Community Moderators at report.complaints@healthdatainsight.org.uk.
|
|
79
48
|
|
|
80
|
-
|
|
81
|
-
clarity around the nature of the violation and an explanation of why the
|
|
82
|
-
behavior was inappropriate. A public apology may be requested.
|
|
49
|
+
Community Moderators take reports of violations seriously and will make every effort to respond in a timely manner. They will investigate all reports of code of conduct violations, reviewing messages, logs, and recordings, or interviewing witnesses and other participants. Community Moderators will keep investigation and enforcement actions as transparent as possible while prioritizing safety and confidentiality. In order to honor these values, enforcement actions are carried out in private with the involved parties, but communicating to the whole community may be part of a mutually agreed upon resolution.
|
|
83
50
|
|
|
84
|
-
|
|
51
|
+
## Addressing and Repairing Harm
|
|
85
52
|
|
|
86
|
-
|
|
87
|
-
actions.
|
|
53
|
+
If an investigation by the Community Moderators finds that this Code of Conduct has been violated, the following enforcement ladder may be used to determine how best to repair harm, based on the incident's impact on the individuals involved and the community as a whole. Depending on the severity of a violation, lower rungs on the ladder may be skipped.
|
|
88
54
|
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
55
|
+
1) Warning
|
|
56
|
+
1) Event: A violation involving a single incident or series of incidents.
|
|
57
|
+
2) Consequence: A private, written warning from the Community Moderators.
|
|
58
|
+
3) Repair: Examples of repair include a private written apology, acknowledgement of responsibility, and seeking clarification on expectations.
|
|
59
|
+
2) Temporarily Limited Activities
|
|
60
|
+
1) Event: A repeated incidence of a violation that previously resulted in a warning, or the first incidence of a more serious violation.
|
|
61
|
+
2) Consequence: A private, written warning with a time-limited cooldown period designed to underscore the seriousness of the situation and give the community members involved time to process the incident. The cooldown period may be limited to particular communication channels or interactions with particular community members.
|
|
62
|
+
3) Repair: Examples of repair may include making an apology, using the cooldown period to reflect on actions and impact, and being thoughtful about re-entering community spaces after the period is over.
|
|
63
|
+
3) Temporary Suspension
|
|
64
|
+
1) Event: A pattern of repeated violation which the Community Moderators have tried to address with warnings, or a single serious violation.
|
|
65
|
+
2) Consequence: A private written warning with conditions for return from suspension. In general, temporary suspensions give the person being suspended time to reflect upon their behavior and possible corrective actions.
|
|
66
|
+
3) Repair: Examples of repair include respecting the spirit of the suspension, meeting the specified conditions for return, and being thoughtful about how to reintegrate with the community when the suspension is lifted.
|
|
67
|
+
4) Permanent Ban
|
|
68
|
+
1) Event: A pattern of repeated code of conduct violations that other steps on the ladder have failed to resolve, or a violation so serious that the Community Moderators determine there is no way to keep the community safe with this person as a member.
|
|
69
|
+
2) Consequence: Access to all community spaces, tools, and communication channels is removed. In general, permanent bans should be rarely used, should have strong reasoning behind them, and should only be resorted to if working through other remedies has failed to change the behavior.
|
|
70
|
+
3) Repair: There is no possible repair in cases of this severity.
|
|
95
71
|
|
|
96
|
-
|
|
72
|
+
This enforcement ladder is intended as a guideline. It does not limit the ability of Community Managers to use their discretion and judgment, in keeping with the best interests of our community.
|
|
97
73
|
|
|
98
|
-
|
|
99
|
-
sustained inappropriate behavior.
|
|
100
|
-
|
|
101
|
-
**Consequence**: A temporary ban from any sort of interaction or public
|
|
102
|
-
communication with the community for a specified period of time. No public or
|
|
103
|
-
private interaction with the people involved, including unsolicited interaction
|
|
104
|
-
with those enforcing the Code of Conduct, is allowed during this period.
|
|
105
|
-
Violating these terms may lead to a permanent ban.
|
|
106
|
-
|
|
107
|
-
### 4. Permanent Ban
|
|
108
|
-
|
|
109
|
-
**Community Impact**: Demonstrating a pattern of violation of community
|
|
110
|
-
standards, including sustained inappropriate behavior, harassment of an
|
|
111
|
-
individual, or aggression toward or disparagement of classes of individuals.
|
|
74
|
+
## Scope
|
|
112
75
|
|
|
113
|
-
|
|
114
|
-
community.
|
|
76
|
+
This Code of Conduct applies within all community spaces, and also applies when an individual is officially representing the community in public or other spaces. Examples of representing our community include using an official email address, posting via an official social media account, or acting as an appointed representative at an online or offline event.
|
|
115
77
|
|
|
116
78
|
## Attribution
|
|
117
79
|
|
|
118
|
-
This Code of Conduct is adapted from the
|
|
119
|
-
version 2.1, available at
|
|
120
|
-
[https://www.contributor-covenant.org/version/2/1/code_of_conduct.html][v2.1].
|
|
121
|
-
|
|
122
|
-
Community Impact Guidelines were inspired by
|
|
123
|
-
[Mozilla's code of conduct enforcement ladder][Mozilla CoC].
|
|
80
|
+
This Code of Conduct is adapted from the Contributor Covenant, version 3.0, permanently available at [https://www.contributor-covenant.org/version/3/0/](https://www.contributor-covenant.org/version/3/0/).
|
|
124
81
|
|
|
125
|
-
|
|
126
|
-
[https://www.contributor-covenant.org/faq][FAQ]. Translations are available at
|
|
127
|
-
[https://www.contributor-covenant.org/translations][translations].
|
|
82
|
+
Contributor Covenant is stewarded by the Organization for Ethical Source and licensed under CC BY-SA 4.0. To view a copy of this license, visit [https://creativecommons.org/licenses/by-sa/4.0/](https://creativecommons.org/licenses/by-sa/4.0/)
|
|
128
83
|
|
|
129
|
-
[
|
|
130
|
-
[v2.1]: https://www.contributor-covenant.org/version/2/1/code_of_conduct.html
|
|
131
|
-
[Mozilla CoC]: https://github.com/mozilla/diversity
|
|
132
|
-
[FAQ]: https://www.contributor-covenant.org/faq
|
|
133
|
-
[translations]: https://www.contributor-covenant.org/translations
|
|
84
|
+
For answers to common questions about Contributor Covenant, see the FAQ at [https://www.contributor-covenant.org/faq](https://www.contributor-covenant.org/faq). Translations are provided at [https://www.contributor-covenant.org/translations](https://www.contributor-covenant.org/translations). Additional enforcement and community guideline resources can be found at [https://www.contributor-covenant.org/resources](https://www.contributor-covenant.org/resources). The enforcement ladder was inspired by the work of [Mozilla’s code of conduct team](https://github.com/mozilla/inclusion).
|
data/CONTRIBUTING.md
ADDED
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
# Contributing
|
|
2
|
+
|
|
3
|
+
Bug reports and pull requests are welcome on GitHub at
|
|
4
|
+
<https://github.com/HealthDataInsight/way_of_working>. This project is intended to be a safe,
|
|
5
|
+
welcoming space for collaboration, and contributors are expected to adhere to the
|
|
6
|
+
[code of conduct](CODE_OF_CONDUCT.md).
|
|
7
|
+
|
|
8
|
+
## Development
|
|
9
|
+
|
|
10
|
+
After checking out the repo, run `bin/setup` to install dependencies. Then run `rake test` to run
|
|
11
|
+
the tests. You can also run `bin/console` for an interactive prompt that lets you experiment.
|
|
12
|
+
|
|
13
|
+
## Versioning
|
|
14
|
+
|
|
15
|
+
This project follows [Semantic Versioning](https://semver.org/spec/v2.0.0.html), but SemVer here
|
|
16
|
+
governs the gem's **public interface**, not the content of the artefacts its generators emit. The
|
|
17
|
+
versioned contract is:
|
|
18
|
+
|
|
19
|
+
* the **CLI surface** — commands and their required options;
|
|
20
|
+
* the **require paths** of built-in features
|
|
21
|
+
(e.g. `require 'way_of_working/code_of_conduct/contributor_covenant'`);
|
|
22
|
+
* the **plugin registration API** (`SubCommands::*.register`, the `way_of_working-*` autoload).
|
|
23
|
+
|
|
24
|
+
Refreshing the standard a feature embeds (e.g. a new Contributor Covenant or MADR version) changes
|
|
25
|
+
generated content but not the interface, so it is **not** a major change. See
|
|
26
|
+
[ADR-0001](docs/decisions/0001-version-the-gem-interface-not-generated-content.md) for the full
|
|
27
|
+
rationale.
|
|
28
|
+
|
|
29
|
+
### Choosing the version bump
|
|
30
|
+
|
|
31
|
+
| Change | Bump |
|
|
32
|
+
| --- | --- |
|
|
33
|
+
| Rename/remove a command or required option, move a feature's require path, or change the plugin API | **MAJOR** |
|
|
34
|
+
| Refresh the standard a feature embeds; add a new feature or variant | **MINOR** |
|
|
35
|
+
| Drastic standard upgrade shipped as a **new variant** alongside the existing one | **MINOR** (additive) |
|
|
36
|
+
| Bug fix in generation or generated output | **PATCH** |
|
|
37
|
+
|
|
38
|
+
For a standard update drastic enough to surprise existing users, add a **new variant** under the feature's `category/variant`
|
|
39
|
+
namespace rather than mutating the existing one. Both variants then coexist and consumers opt in by
|
|
40
|
+
require path — keeping the change additive and leaving existing users untouched. Where we deliberately drop the old
|
|
41
|
+
version instead (as with Contributor Covenant 2.1 → 3), upgrade the existing variant in place.
|
|
42
|
+
|
|
43
|
+
### Changelog convention
|
|
44
|
+
|
|
45
|
+
All notable changes are recorded in `CHANGELOG.md` following
|
|
46
|
+
[Keep a Changelog](https://keepachangelog.com/en/1.1.0/). Scope feature-affecting entries with a
|
|
47
|
+
bold feature prefix so each feature's history stays greppable within the single file, e.g.:
|
|
48
|
+
|
|
49
|
+
```text
|
|
50
|
+
- **Code of Conduct:** upgraded Contributor Covenant 2.1 → 3
|
|
51
|
+
```
|
|
52
|
+
|
|
53
|
+
## Releasing
|
|
54
|
+
|
|
55
|
+
To install this gem onto your local machine, run `bundle exec rake install`. To release a new
|
|
56
|
+
version:
|
|
57
|
+
|
|
58
|
+
1. Decide the bump using the table above.
|
|
59
|
+
2. Update the version number in `lib/way_of_working/version.rb`.
|
|
60
|
+
3. Move the `[Unreleased]` changelog entries under the new version heading.
|
|
61
|
+
4. Run `bundle exec rake release`, which creates a git tag for the version, pushes the commits and
|
|
62
|
+
tag, and pushes the `.gem` file to [rubygems.org](https://rubygems.org).
|