Contributions are very welcome. The following will provide some helpful guidelines.
Each commit should be atomic and pass all tests. Logically unrelated changes should not be gathered in one commit.
Commit messages should be clear and fully elaborate the context and the reason for a change. The first line should contain a brief imperative summary starting with a capitalized character and be followed by a more detailed explanatory text separated by an empty line. If your commit refers to an issue, please post-fix it with the issue number.
Example:
Short summary of changes (72 characters or less)
More detailed explanatory text, if necessary. This text can have
several lines.
Issue: #123 (this line is optional)
Furthermore, commits should be signed off according to the DCO.
Pull requests should have a clear description that fully elaborates the context and the reason for a change. The corresponding template should be used. If your pull request resolves an issue, please add a respective line to the end.
OpossumUI is an Electron app written in TypeScript. The frontend uses React (where functional components are used whenever possible) with Redux for state management.
Development under Linux and macOS is fully supported: Development under Windows has currently the following limitations:
- only Windows executables can be built,
- "version unknown" is written in the built app instead of the commit hash
Clone the OpossumUI repo. E.g. run the following command in a terminal:
git clone git@github.com:opossum-tool/OpossumUI.git
To install dependencies and set up the working environment, go to the repository root directory and run:
yarn install
All useful scripts are listed in the package.json and can be run through yarn
and can be called after cloning the
repository and installing all dependencies. To start the app based on the current state of the code, including automatic
updates after changes to the frontend, execute:
yarn start
Unit tests are provided for all features, aided by integration tests when helpful. The testing framework is jest + react testing library. They can be run locally by executing:
yarn test:local
to run a subset of all tests. To run all tests:
yarn test:unit
yarn test:integration-ci
End to end test are available and can be run using:
yarn test:e2e
Prettier is used as a code formatter.
The following software is required for working on the repository:
- git,
- node.js 18,
- yarn,
- reuse.software (to check that copyright information is provided),
- wine (only to build the Windows version).
To build for a single OS run either yarn ship-linux
, yarn ship-mac
or yarn ship-win
. To build for all three
systems run yarn ship
.
Important: wine must be installed to build a Windows installer on a non-Windows system.
The built release(s) can be found under /release