This library is hosted on Github, contributions are more then welcome.
- Fork library
- Compile the library
- Run the tests
- Run documentation generator locally
- Contributors ✨
You should start by creating a fork. Or if you already had a fork sync the fork:
# Add the remote, call it "upstream": (only once) git remote add upstream https://github.com/svrooij/sonos2mqtt.git # Fetch all the branches of that remote into remote-tracking branches, # such as upstream/master: git fetch upstream # Make sure that you're on your master branch: git checkout master # Rewrite your master branch so that any commits of yours that # aren't already in upstream/master are replayed on top of that # other branch: git rebase upstream/master
Before you can use this library is has to be compiled.
npm run install && npm run build
After changing somehting you should run the tests (as they are automatically run before your PR is accepted).
npm run test
It’s also important to start the app and test it in your local environment. If you don’t want to use your production mqtt server. Just start a temporary one with docker.
This library has a VSCode task defined, be sure to change your sonos host in the
.vscode/launch.json file. You should be able to debug the library in VSCode with breakpoints and everything.
The documentation can be found in /docs and uses Jekyll to convert the markdown to html. To check the generated documenation locally you can use the following script. It uses docker, so it won’t install anything on your machine. It also has live reload to you can edit and save and should see the changes instantly.
npm run serve-docs
Thanks goes to these wonderful people (emoji key):
This project follows the all-contributors specification. Contributions of any kind welcome!
Tag the all-contributors bot in your PR and you will get added automically to the list of contributors.