nest-cli
Version:
Unofficial command-line tool to control Nest devices
20 lines (15 loc) • 452 B
JavaScript
;
const SetTempTask = require('../tasks/temp');
const readThermostatId = require('../utils/read-thermostat-id');
module.exports = {
name: 'temp <mode> <temp> [thermostatId]',
alias: 't',
description: 'modes: cool, heat, heat-cool',
run: readThermostatId(function(mode, temp, thermostatId) {
const task = new SetTempTask({
app: this.app,
ui: this.ui
});
return task.run(thermostatId, mode, temp);
})
};