We welcome contributions from the community and first want to thank you for taking the time to contribute!
Please familiarize yourself with the Code of Conduct before contributing.
Before you start working with Repository Service for TUF, please read our Developer Certificate of Origin. All contributions to this repository must be signed as described on that page.
To acknowledge the Developer Certificate of Origin (DCO), sign your commits
by appending a Signed-off-by:
Your Name <[email protected]>
to each git commit message (see git commit
--signoff).
Your signature certifies that you wrote the patch or have the right to pass it
on as an open-source patch.
We welcome many different types of contributions and not all of them need a Pull Request. Contributions may include:
- New features and proposals
- Documentation
- Bug fixes
- Issue Triage
- Answering questions and giving feedback
- Helping to onboard new contributors
- Other related activities
- Python >=3.9
- Pipenv
Fork the repository on GitHub and clone it to your local machine:
git clone [email protected]:YOUR-USERNAME/repository-service-tuf-cli.git
Add a remote and regularly sync to make sure you stay up-to-date with our repository:
git remote add upstream https://github.com/repository-service-tuf/repository-service-tuf-cli
git checkout main
git fetch upstream
git merge upstream/main
After installing Python, install the pipenv tool:
$ pip install pipenv
Create a virtual environment for this project:
$ pipenv shell
Install the requirements from the Pipfile.
The flag -d will install the development requirements:
$ pipenv install -d
Note
macOS running on MacBook M1
For developers, after the above command, run:
$ pip uninstall cryptography cffi -y
$ pip cache purge
$ LDFLAGS=-L$(brew --prefix libffi)/lib CFLAGS=-I$(brew --prefix libffi)/include pip install cffi cryptography
The pre-commit tool is installed as part of the development requirements.
To automatically run checks before you commit your changes you should run:
$ make precommit
This will install the git hook scripts for the first time, update to the
latest versions of the hooks and run the pre-commit tool.
Now pre-commit
will run automatically on git commit
.
$ rstuf
Usage: rstuf [OPTIONS] COMMAND [ARGS]...
Repository Service for TUF Command Line Interface (CLI).
Install the requirements package.
The flag -d will install the development requirements.
$ pipenv install -d <package>
$ pipenv install <package>
$ make requirements
Perform automated testing with the tox tool:
$ tox