Warning, /jana2/docs/development/contributing.md is written in an unsupported language. File is not indexed.
0001 Contributing
0002 ============
0003
0004 ## Coding Conventions
0005
0006 - Use `std::shared_ptr` and `std::unique_ptr` internally, but don't make them be part of the API. Instead, pass a lightweight wrapper object that encapsulates the ownership model. For example, use `JComponent::Service` instead of `std::shared_ptr<JService>`.
0007
0008 - Use `#pragma once` instead of traditional header guards
0009
0010 - Methods that are part of the API are always in `PascalCase()`; methods that are not part of the contract with the user _may_ be `snake_cased`, though new code should make everything Pascal-cased. Member variables are snake-cased and prefixed with `m_`. Indent using 4 spaces, not tabs.
0011
0012
0013 ## Cutting a release
0014
0015 1. Figure out the version number. We use calendar versioning with the schema YEAR.MAJOR.PATCH:
0016
0017 - YEAR: This is chosen so that it is immediately obvious when a dependency is out-of-date, and prevents the MAJOR number from becoming too large to be meaningful.
0018
0019 - MAJOR: This is incremented for larger changes such as features, refactorings, and larger bug fixes. These may or may not be backwards compatible in practice, but should be thoroughly tested downstream regardless. One-indexed.
0020
0021 - PATCH: This is for small, carefully-scoped bug fixes only. New patch releases may be issued for older releases as needed. Zero-indexed.
0022
0023 2. Update the root CMakeLists.txt to use the new version number. Update the documentation at `docs/Download.md` to include the release description. Commit these changes.
0024
0025 3. Create a tag pointing to the commit you just made. The tag should have the same name as the CMake version, prefixed with a 'v'. Push to GitHub. Don't force push this tags, because people downstream have CI tools that cache their dependencies using the tag name instead of the hash. Instead, just cut a new release candidate.
0026
0027 4. Cut a release on GitHub, pointing to that tag. Update the `latest-release` branch to point to the new release.
0028
0029 5. Figure out the SHA256 of the release tarball on Github:
0030 ```bash
0031 shasum -a 256 $PATH_TO_JANA_TARBALL
0032 ```
0033
0034 5. Pull-request an update to the eicrecon spack repository. The repository is here:
0035
0036 https://github.com/eic/eic-spack
0037
0038
0039 Add a line to `packages/jana2/package.py` that associates the release version with the checksum you calculated in (5), e.g.:
0040
0041 ```python
0042 version("2.2.1-rc1", sha256="7b65ce967d9c0690e22f4450733ead4acebf8fa510f792e0e4a6def14fb739b1")
0043 ```
0044 Note that the spack version identifier does _not_ have a 'v' prefix.
0045
0046