new cli option (#3247)
This commit is contained in:
parent
6ba9d4bc5f
commit
c69010389f
|
|
@ -74,6 +74,10 @@ function validateInput(argv) {
|
|||
return 'Error: You can only run with one browser at a time.';
|
||||
}
|
||||
|
||||
if (argv.outputFolder && argv.copyLatestFilesToBase) {
|
||||
return 'Error: Setting --outputfolder do not work together with --copyLatestFilesToBase';
|
||||
}
|
||||
|
||||
if (argv.slug) {
|
||||
const characters = /[^A-Za-z_\-0-9]/g;
|
||||
if (characters.test(argv.slug)) {
|
||||
|
|
@ -1134,7 +1138,7 @@ module.exports.parseCommandLine = function parseCommandLine() {
|
|||
.option('s3.path', {
|
||||
describe:
|
||||
"Override the default folder path in the bucket where the results are uploaded. By default it's " +
|
||||
'"DOMAIN_OR_FILENAME/TIMESTAMP", or the name of the folder if --outputFolder is specified.',
|
||||
'"DOMAIN_OR_FILENAME_OR_SLUG/TIMESTAMP", or the name of the folder if --outputFolder is specified.',
|
||||
group: 's3'
|
||||
})
|
||||
.option('s3.region', {
|
||||
|
|
@ -1196,7 +1200,7 @@ module.exports.parseCommandLine = function parseCommandLine() {
|
|||
.option('gcs.path', {
|
||||
describe:
|
||||
"Override the default folder path in the bucket where the results are uploaded. By default it's " +
|
||||
'"DOMAIN_OR_FILENAME/TIMESTAMP", or the name of the folder if --outputFolder is specified.',
|
||||
'"DOMAIN_OR_FILENAME_OR_SLUG/TIMESTAMP", or the name of the folder if --outputFolder is specified.',
|
||||
group: 'GoogleCloudStorage'
|
||||
})
|
||||
.option('gcs.removeLocalResult', {
|
||||
|
|
@ -1326,9 +1330,16 @@ module.exports.parseCommandLine = function parseCommandLine() {
|
|||
type: 'boolean'
|
||||
})
|
||||
.option('outputFolder', {
|
||||
describe: 'The folder where the result will be stored.',
|
||||
describe:
|
||||
'The folder where the result will be stored. If you do not set it, the result will be stored in "DOMAIN_OR_FILENAME_OR_SLUG/TIMESTAMP"',
|
||||
type: 'string'
|
||||
})
|
||||
.option('copyLatestFilesToBase', {
|
||||
default: false,
|
||||
describe:
|
||||
'Copy the latest screenshots to the root folder (so you can include it in Grafana). Do not work together it --outputFolder.',
|
||||
type: 'boolean'
|
||||
})
|
||||
.option('firstParty', {
|
||||
describe:
|
||||
'A regex running against each request and categorize it as first vs third party URL. (ex: ".*sitespeed.*")'
|
||||
|
|
|
|||
Loading…
Reference in New Issue