|
| 1 | +This is a C++ based repository that uses Qt5 as a primary support and GUI library. This repository is for a password manager application that stores passwords |
| 2 | +and other highly sensitive information. The data format that passwords are stored is called KDBX which is a mixed binary and XML format that is fully encrypted |
| 3 | +at rest. This format is unpacked into a series of data structures: Database, Groups, and Entries. Please follow these guidelines when contributing: |
| 4 | + |
| 5 | +## Code Standards |
| 6 | + |
| 7 | +### Required Before Each Commit |
| 8 | +- Run `cmake --build . --target format` before committing any changes to ensure proper code formatting |
| 9 | +- This will run clang-format to ensure all code conforms to the style guide |
| 10 | +- From the checkout directory, also run `./release-tool i18n lupdate` to update translation files |
| 11 | + |
| 12 | +### Development Flow |
| 13 | +- Setup Build Folder: `mkdir build; cd build` |
| 14 | +- Configure: `cmake -G Ninja -DWITH_XC_ALL=ON -DWITH_GUI_TESTS=ON ..` |
| 15 | +- Build: `cmake --build . -- -j $(nproc)` |
| 16 | +- Test: `ctest` |
| 17 | + |
| 18 | +## Repository Structure |
| 19 | +- `docs/topics`: Documentation written in asciidoctor syntax |
| 20 | +- `src/`: Main source code files are under this subdirectory |
| 21 | +- `src/autotype`: Code that emulates a virtual keyboard to type into interfaces |
| 22 | +- `src/browser`: Interface with the KeePassXC Browser Extension using a JSON-based protocol |
| 23 | +- `src/cli`: Command Line Interface code |
| 24 | +- `src/core`: Contains files that define the data model and other shared code structures |
| 25 | +- `src/format`: Code for import/export and reading/writing of KDBX databases |
| 26 | +- `src/fdosecrets`: freedesktop.org Secret Service interface code |
| 27 | +- `src/quickunlock`: Quick unlock interfaces for various platforms |
| 28 | +- `src/sshagent`: SSH Agent interface code to load private keys from the database into ssh-agent |
| 29 | +- `tests/`: Test source code files |
| 30 | +- `tests/gui`: GUI test source code files |
| 31 | + |
| 32 | +## Key Guidelines |
| 33 | +1. Follow C++20 and Qt5 best practices and idiomatic patterns |
| 34 | +2. Maintain existing code structure and organization |
| 35 | +3. Prefer not to edit cryptographic handling code or other sensitive parts of the code base |
| 36 | +4. Write unit tests for new functionality using QTest scaffolding |
| 37 | +5. Suggest changes to the `docs/topics` folder when appropriate |
| 38 | +6. Unless the change is simple, don't actually make edits to .ui files, just suggest the changes needed |
0 commit comments