Closed djm300 closed 7 years ago
I like this. Something I wanted to add at some point anyways. The only thing I would like to do is add an additional config option to hide devices. At my house for example there are some devices that I never use for music so I exclude them from my config. I will merge this pull and then add the additional config option.
Thanks for contributing!
Okay I merged and then made a few changes. I noticed you were using the hostnames as the zone names. I changed it to use the advertized "name" for the zone name. I also added logic to ignore node-airplayhub. No need for a feedback loop. Hehe. I also added a hidden option to zones so you can hide zones you don't want on the list. You can also show/hide zones with these URLs: /hidezone/[zonename] /showzone/[zonename]
Oh and the config file will now self generate if the file doesn't exist. This, along with your contribution should make initial configuration dummy proof. Thanks again for your help!
I added a rough POC to populate the ./config.json with detected Airplay devices. If devices drop off, the code does not delete them from the web gui / the zones array.
Note: this requires the bonjour package.