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. Use semver: the first number is a "major" version number that has nothing to do with the fact that this is "JANA2".
0016 Use release candidates when necessary. The version number convention is `v{MAJOR}.{MINOR}.{PATCH}-rc{CANDIDATE}`.
0017
0018 2. Update the root CMakeLists.txt to use that version number. Update the documentation at `docs/Download.md` to include a link to where the new release will be available on GitHub. Commit these changes.
0019
0020 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.
0021
0022 4. Cut a release on GitHub, pointing to that tag. If it is a release candidiate, mark it as a prerelease.
0023
0024 5. Figure out the SHA256 of the release tarball on Github:
0025 ```bash
0026 shasum -a 256 $PATH_TO_JANA_TARBALL
0027 ```
0028
0029 5. Pull-request an update to the eicrecon spack repository. The repository is here:
0030
0031 https://github.com/eic/eic-spack
0032
0033
0034 Add a line to `packages/jana2/package.py` that associates the release version with the checksum you calculated in (5), e.g.:
0035
0036 ```python
0037 version("2.2.1-rc1", sha256="7b65ce967d9c0690e22f4450733ead4acebf8fa510f792e0e4a6def14fb739b1")
0038 ```
0039 Note that the spack version identifier does _not_ have a 'v' prefix.
0040
0041