Add option to control screen resetting on device release

This commit is contained in:
Piotr Orzechowski
2018-03-07 11:11:27 +01:00
parent 4463fe139c
commit e8db600878
4 changed files with 25 additions and 2 deletions

View File

@@ -122,6 +122,12 @@ module.exports.builder = function(yargs) {
, type: 'number'
, default: 30000
})
.option('screen-reset', {
describe: 'Go back to home screen and reset screen rotation ' +
'when user releases device. Negate with --no-screen-reset.'
, type: 'boolean'
, default: true
})
.option('screen-ws-url-pattern', {
describe: 'The URL pattern to use for the screen WebSocket.'
, type: 'string'
@@ -199,6 +205,7 @@ module.exports.handler = function(argv) {
}, []))
.concat(argv.lockRotation ? ['--lock-rotation'] : [])
.concat(!argv.cleanup ? ['--no-cleanup'] : [])
.concat(!argv.screenReset ? ['--no-screen-reset'] : [])
return fork(cli, args)
}