@percy/cli-app 1.10.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +18 -0
- package/README.md +38 -0
- package/dist/app.js +8 -0
- package/dist/exec.js +24 -0
- package/dist/index.js +2 -0
- package/package.json +39 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
Copyright © Perceptual Inc.
|
|
2
|
+
|
|
3
|
+
The MIT License (MIT)
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and
|
|
6
|
+
associated documentation files (the "Software"), to deal in the Software without restriction,
|
|
7
|
+
including without limitation the rights to use, copy, modify, merge, publish, distribute,
|
|
8
|
+
sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is
|
|
9
|
+
furnished to do so, subject to the following conditions:
|
|
10
|
+
|
|
11
|
+
The above copyright notice and this permission notice shall be included in all copies or substantial
|
|
12
|
+
portions of the Software.
|
|
13
|
+
|
|
14
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT
|
|
15
|
+
NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
|
16
|
+
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES
|
|
17
|
+
OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
|
|
18
|
+
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
package/README.md
ADDED
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
# @percy/cli-app
|
|
2
|
+
|
|
3
|
+
Percy CLI commands for running Percy with native apps.
|
|
4
|
+
|
|
5
|
+
## Commands
|
|
6
|
+
<!-- commands -->
|
|
7
|
+
* [`percy app:exec`](#percy-appexec)
|
|
8
|
+
|
|
9
|
+
### `percy app:exec`
|
|
10
|
+
|
|
11
|
+
Start and stop Percy around a supplied command for native apps
|
|
12
|
+
|
|
13
|
+
```
|
|
14
|
+
Usage:
|
|
15
|
+
$ percy app:exec [options] -- <command>
|
|
16
|
+
|
|
17
|
+
Subcommands:
|
|
18
|
+
app:exec:start [options] Starts a locally running Percy process for native apps
|
|
19
|
+
app:exec:stop [options] Stops a locally running Percy process
|
|
20
|
+
app:exec:ping [options] Pings a locally running Percy process
|
|
21
|
+
help [command] Display command help
|
|
22
|
+
|
|
23
|
+
Options:
|
|
24
|
+
--parallel Marks the build as one of many parallel builds
|
|
25
|
+
--partial Marks the build as a partial build
|
|
26
|
+
|
|
27
|
+
Percy options:
|
|
28
|
+
-c, --config <file> Config file path
|
|
29
|
+
-d, --dry-run Print snapshot names only
|
|
30
|
+
-P, --port [number] Local CLI server port (default: 5338)
|
|
31
|
+
|
|
32
|
+
Global options:
|
|
33
|
+
-v, --verbose Log everything
|
|
34
|
+
-q, --quiet Log errors only
|
|
35
|
+
-s, --silent Log nothing
|
|
36
|
+
-h, --help Display command help
|
|
37
|
+
```
|
|
38
|
+
<!-- commandsstop -->
|
package/dist/app.js
ADDED
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import command from '@percy/cli-command';
|
|
2
|
+
import exec from './exec.js';
|
|
3
|
+
export const app = command('app', {
|
|
4
|
+
description: 'Create Percy builds for native app snapshots',
|
|
5
|
+
hidden: 'This command is still in development and may not work as expected',
|
|
6
|
+
commands: [exec]
|
|
7
|
+
});
|
|
8
|
+
export default app;
|
package/dist/exec.js
ADDED
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import command from '@percy/cli-command';
|
|
2
|
+
import * as ExecPlugin from '@percy/cli-exec';
|
|
3
|
+
export const ping = ExecPlugin.ping;
|
|
4
|
+
export const stop = ExecPlugin.stop;
|
|
5
|
+
export const start = command('start', {
|
|
6
|
+
description: 'Starts a locally running Percy process for native apps',
|
|
7
|
+
examples: ['$0 &> percy.log'],
|
|
8
|
+
percy: {
|
|
9
|
+
server: true,
|
|
10
|
+
skipDiscovery: true
|
|
11
|
+
}
|
|
12
|
+
}, ExecPlugin.start.callback);
|
|
13
|
+
export const exec = command('exec', {
|
|
14
|
+
description: 'Start and stop Percy around a supplied command for native apps',
|
|
15
|
+
usage: '[options] -- <command>',
|
|
16
|
+
commands: [start, stop, ping],
|
|
17
|
+
flags: ExecPlugin.default.definition // grouped flags are built-in flags
|
|
18
|
+
.flags.filter(f => !f.group),
|
|
19
|
+
percy: {
|
|
20
|
+
server: true,
|
|
21
|
+
skipDiscovery: true
|
|
22
|
+
}
|
|
23
|
+
}, ExecPlugin.default.callback);
|
|
24
|
+
export default exec;
|
package/dist/index.js
ADDED
package/package.json
ADDED
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@percy/cli-app",
|
|
3
|
+
"version": "1.10.0",
|
|
4
|
+
"license": "MIT",
|
|
5
|
+
"repository": {
|
|
6
|
+
"type": "git",
|
|
7
|
+
"url": "https://github.com/percy/cli",
|
|
8
|
+
"directory": "packages/cli-app"
|
|
9
|
+
},
|
|
10
|
+
"publishConfig": {
|
|
11
|
+
"access": "public"
|
|
12
|
+
},
|
|
13
|
+
"engines": {
|
|
14
|
+
"node": ">=14"
|
|
15
|
+
},
|
|
16
|
+
"files": [
|
|
17
|
+
"dist"
|
|
18
|
+
],
|
|
19
|
+
"main": "./dist/index.js",
|
|
20
|
+
"type": "module",
|
|
21
|
+
"exports": "./dist/index.js",
|
|
22
|
+
"scripts": {
|
|
23
|
+
"build": "node ../../scripts/build",
|
|
24
|
+
"lint": "eslint --ignore-path ../../.gitignore .",
|
|
25
|
+
"readme": "percy-cli-readme",
|
|
26
|
+
"test": "node ../../scripts/test",
|
|
27
|
+
"test:coverage": "yarn test --coverage"
|
|
28
|
+
},
|
|
29
|
+
"@percy/cli": {
|
|
30
|
+
"commands": [
|
|
31
|
+
"./dist/app.js"
|
|
32
|
+
]
|
|
33
|
+
},
|
|
34
|
+
"dependencies": {
|
|
35
|
+
"@percy/cli-command": "1.10.0",
|
|
36
|
+
"@percy/cli-exec": "1.10.0"
|
|
37
|
+
},
|
|
38
|
+
"gitHead": "a6934eda4fc3b84845ae606d7f5a901f25e0a56f"
|
|
39
|
+
}
|