-
-
Notifications
You must be signed in to change notification settings - Fork 142
Allow (optional) manual specification of accessory information #165
Allow (optional) manual specification of accessory information #165
Conversation
@schmittx, thanks for your PR! By analyzing the history of the files in this pull request, we identified @robbiet480, @rcloran and @shmuelzon to be potential reviewers. |
accessories/cover.js
Outdated
this.model = String(data.attributes.homebridge_model); | ||
} else { | ||
this.model = 'Rollershutter'; | ||
} this.service = new Service.WindowCovering(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Multiple spaces found before 'this' no-multi-spaces
accessories/climate.js
Outdated
if (data.attributes && data.attributes.homebridge_model) { | ||
this.model = String(data.attributes.homebridge_model); | ||
} else { | ||
this.model = `${toTitleCase(data.attributes.device_class)} Binary Sensor`; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
'toTitleCase' is not defined no-undef
accessories/binary_sensor.js
Outdated
this.service = service; | ||
this.characteristic = characteristic; | ||
this.onValue = onValue; | ||
this.offValue = offValue; | ||
this.offValue = offValue; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Trailing spaces not allowed no-trailing-spaces
accessories/climate.js
Outdated
if (data.attributes && data.attributes.homebridge_model) { | ||
this.model = String(data.attributes.homebridge_model); | ||
} else { | ||
this.model = `Climate`; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Strings must use singlequote quotes
accessories/climate.js
Outdated
if (data.attributes && data.attributes.homebridge_model) { | ||
this.model = String(data.attributes.homebridge_model); | ||
} else { | ||
this.model = `Climate`; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Strings must use singlequote quotes
Apologies for the messy commit history, I'm still getting the hang of GitHub. I think this should be good to go now though. |
@schmittx If you can go ahead and fix the merge conflict I'll get this merged. Going to cut a new version now, as soon as you get this fixed I will cut another version for you. |
@robbiet480 sounds good, I'll get it cleaned up this weekend. I'll also be making some new PRs as well, I've got air quality (binary) sensors working, battery tracking, and some other things working. |
Should be good to go now! |
@schmittx Did you have other PRs that you planned to open soon? If so, i'll merge this but wait to cut a release so you can get your other PRs in. |
@robbiet480 scratch that, go ahead and merge this PR and cut a new release. I'm pretty sure the new stuff I'm planning to submit will cause a number of conflicts when trying to merge with this PR. I'd rather start from a clean point. I'm planning to clean up a number of the files and (hopefully) simplify some of the required information by reducing the number of |
@schmittx I can just merge and not cut a release yet. |
Adds ability to manually specify accessory information for each entity (if not specified, Homebridge will set it automatically).
You can specify the information (manufacturer, model, and serial number) using the following in customize.