mirror of
https://github.com/DeviceFarmer/stf.git
synced 2026-04-19 08:33:24 +02:00
Merge pull request #768 from 0rzech/screen-reset-option
Screen reset option
This commit is contained in:
@@ -108,6 +108,12 @@ module.exports.builder = function(yargs) {
|
||||
, type: 'number'
|
||||
, demand: true
|
||||
})
|
||||
.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'
|
||||
@@ -165,5 +171,6 @@ module.exports.handler = function(argv) {
|
||||
, muteMaster: argv.muteMaster
|
||||
, lockRotation: argv.lockRotation
|
||||
, cleanup: argv.cleanup
|
||||
, screenReset: argv.screenReset
|
||||
})
|
||||
}
|
||||
|
||||
@@ -156,6 +156,12 @@ module.exports.builder = function(yargs) {
|
||||
, type: 'string'
|
||||
, default: 'localhost'
|
||||
})
|
||||
.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('serial', {
|
||||
describe: 'Only use devices with these serial numbers.'
|
||||
, type: 'array'
|
||||
@@ -282,6 +288,7 @@ module.exports.handler = function(argv) {
|
||||
.concat(argv.allowRemote ? ['--allow-remote'] : [])
|
||||
.concat(argv.lockRotation ? ['--lock-rotation'] : [])
|
||||
.concat(!argv.cleanup ? ['--no-cleanup'] : [])
|
||||
.concat(!argv.screenReset ? ['--no-screen-reset'] : [])
|
||||
.concat(argv.serial))
|
||||
|
||||
// auth
|
||||
|
||||
@@ -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)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user