Skip to content

Commit 951459d

Browse files
committed
📝 CONTRIBUTING.md
1 parent c35503f commit 951459d

File tree

1 file changed

+54
-0
lines changed

1 file changed

+54
-0
lines changed

CONTRIBUTING.md

+54
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
## Contributing
2+
3+
Bug reports and pull requests are welcome on GitHub at [https://github.com/VitalConnectInc/rack-openid2][🚎src-main]
4+
. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to
5+
the [code of conduct][🤝conduct].
6+
7+
To submit a patch, please fork the project and create a patch with tests.
8+
Once you're happy with it send a pull request.
9+
10+
## Release
11+
12+
### One-time, Per-developer, Setup
13+
14+
**IMPORTANT**: Your public key for signing gems will need to be picked up by the line in the
15+
`gemspec` defining the `spec.cert_chain` (check the relevant ENV variables there),
16+
in order to sign the new release.
17+
See: [RubyGems Security Guide][🔒️rubygems-security-guide]
18+
19+
### To release a new version:
20+
21+
1. Run `bin/setup && bin/rake` as a tests, coverage, & linting sanity check
22+
2. Update the version number in `version.rb`
23+
3. Run `bin/setup && bin/rake` again as a secondary check, and to update `Gemfile.lock`
24+
4. Run `git commit -am "🔖 Prepare release v<VERSION>"` to commit the changes
25+
5. Run `git push` to trigger the final CI pipeline before release, & merge PRs
26+
- NOTE: Remember to [check the build][🧪build]!
27+
6. Run `git checkout main`
28+
7. Run `git pull origin main` to ensure you will release the latest trunk code.
29+
8. Set `SOURCE_DATE_EPOCH` so `rake build` and `rake release` use same timestamp, and generate same checksums
30+
- Run `export SOURCE_DATE_EPOCH=$EPOCHSECONDS && echo $SOURCE_DATE_EPOCH`
31+
- If the echo above has no output, then it didn't work.
32+
- Note that you'll need the `zsh/datetime` module, if running `zsh`.
33+
- In `bash` you can use `date +%s` instead, i.e. `export SOURCE_DATE_EPOCH=$(date +%s) && echo $SOURCE_DATE_EPOCH`
34+
9. Run `bundle exec rake build`
35+
10. Run [`bin/checksums`][🔒️rubygems-checksums-pr] to create SHA-256 and SHA-512 checksums
36+
- Checksums will be committed automatically by the script, but not pushed
37+
11. Run `bundle exec rake release` which will create a git tag for the version,
38+
push git commits and tags, and push the `.gem` file to [rubygems.org][💎rubygems]
39+
40+
## Contributors
41+
42+
[![Contributors][🖐contributors-img]][🖐contributors]
43+
44+
Made with [contributors-img][🖐contrib-rocks].
45+
46+
[🧪build]: https://github.com/VitalConnectInc/rack-openid2/actions
47+
[🤝conduct]: https://github.com/VitalConnectInc/rack-openid2/blob/main/CODE_OF_CONDUCT.md
48+
[🖐contrib-rocks]: https://contrib.rocks
49+
[🖐contributors]: https://github.com/VitalConnectInc/rack-openid2/graphs/contributors
50+
[🖐contributors-img]: https://contrib.rocks/image?repo=VitalConnectInc/rack-openid2
51+
[💎rubygems]: https://rubygems.org
52+
[🔒️rubygems-security-guide]: https://guides.rubygems.org/security/#building-gems
53+
[🔒️rubygems-checksums-pr]: https://github.com/rubygems/guides/pull/325
54+
[🚎src-main]: https://github.com/VitalConnectInc/rack-openid2

0 commit comments

Comments
 (0)