Development and contributing
Contributing to rmpc
Section titled “Contributing to rmpc”Thank you for taking interest in helping rmpc! Hopefully this short guide will help you run and debug the project.
Table of contents
Section titled “Table of contents”- Prerequisites
- Dev setup and running rmpc from the source code
- Formatting the code
- Reporting an issue
- Requesting a feature
- Documentation
Prerequisites
Section titled “Prerequisites”- This guide assumes you are reasonably familiar with git and github.
- You will also need to have rust installed on your system. You can install it from the official website https://www.rust-lang.org/tools/install
Dev setup and running rmpc from the source code
Section titled “Dev setup and running rmpc from the source code”Running rmpc is very straight forward.
-
Ensure you have latest version of rust installed.
-
Clone the repository and switch to the newly created directory
git clone https://github.com/mierak/rmpc.gitcd rmpc
- Run rmpc
# in debug modecargo run# or in release modecargo run --release
- Setup your config file for debug mode
Rmpc will search for config.debug.ron
instead of config.ron
in debug mode. This means you do
not have to change your usual config file to develop and debug rmpc.
You can also use a special Logs
pane your debug config which displays logs directly in rmpc.
Formatting the code
Section titled “Formatting the code”Rmpc uses rustfmt
nightly to format the code.
- Install nightly
rustfmt
rustup component add rustfmt --toolchain nightly
- Format the code
cargo +nightly fmt --all
Reporting an issue
Section titled “Reporting an issue”Please fill the Bug Report template if you encounter an issue which is not yet solved in the current git version of rmpc and include all information relevant to your issue.
Sometimes you might be asked to provide trace
level logs. You can obtain them by running rmpc
with RUST_LOG
environment variable set to trace. The log file is located at /tmp/rmpc.log
.
These logs can be very verbose so you might have to upload them somewhere and link them to the issue.
RUST_LOG=trace rmpc# or if you are running directly from source codeRUST_LOG=trace cargo run
Requesting a feature
Section titled “Requesting a feature”Similar to the bug report, please fill out the Feature Request template.
Documentation
Section titled “Documentation”The documentation lies in the docs
directory in the repository root. The docs area created with
astro javascript framework. All contributions and improvements to the
documentation are welcome.
To run the documentation locally:
- Ensure you have node.js installed.
- Go to the docs directory and install dependencies
cd docsnpm install
- Run the dev server
npm run dev
A local HTTP server will be started. Navigate to http://localhost:4321/rmpc and you should see the docs website. All changes you make to the docs should be automatically reflected in your browser.