Thank you for wanting to contribute to nmrs!
I'm fairly accepting to all PR's, only with a couple caveats:
- Do not submit low-effort or autogenerated code. If you absolutely must, please disclose how you used AI otherwise I will close the PR.
- Please try to (when possible) contribute to an issue. This is not a hard ask, I'll still consider your contribution if it makes sense.
To run or develop nmrs you need:
- Rust (stable) via
rustup - A running
NetworkManagerinstance
I also provide a Dockerfile you can build if you don't use Linux and use MacOS instead.
To run tests:
docker compose run testTo run an interactive shell:
docker compose run shellIt goes without saying that this image only works with nmrs. nmrs-gui requires GTK deps which in that case, you are better off just running a VM or learning how to use Linux on a machine instead.
If you decide to run the shell, ensure you run all commands from within the nmrs directory, not root.
cargo test -p nmrs # run library tests
cargo build -p nmrs # build the library
cargo check # you get the point...To develop nmrs-gui, you'll need:
- GTK4 and libadwaita development libraries
- A Wayland compositor
If the respective branch for a PR goes out of sync, I prefer you rebase. I've exposed this setting for you to to automatically do so as a contributor on any PR you open.
When you've made changes and are ready to commit, I prefer that you follow the standards explained here.
I additionally request that you format your commits as such:
"type((some issue number)): changes made",
i.e.
fix(#24): fixed bug where something was happening
Obviously, if there is no issue number to attach, no need to add anything there.
Lastly, please ensure you make atomic commmits.
All issues are acceptable. If a situation arises where a request or concern is not valid, I will respond directly to the issue.
All tests must pass before a merge takes place.
sudo systemctl start NetworkManagercargo test --all-featuresThese require WiFi hardware. Please make sure you run this locally before your PR to ensure everything works.
cargo test --test integration_test --all-featuresIf you do not have access to WiFi hardware (for whatever odd reason that is), you can do something like this:
sudo modprobe mac80211_hwsim radios=2
cargo test --test integration_test --all-features
sudo modprobe -r mac80211_hwsimNote
This method only works on linux
All contributions fall under the MIT License.