UNPKG

1.55 kBJSONView Raw
1{
2 "$schema": "http://json-schema.org/schema",
3 "$id": "SchematicsRunCommands",
4 "title": "Create a custom target to run any command",
5 "description": "Create a custom target to run any command.",
6 "type": "object",
7 "cli": "nx",
8 "examples": [
9 {
10 "command": "nx g @nrwl/workspace:run-commands printhello --project my-feature-lib --command 'echo hello'",
11 "description": "Add the `printhello` target to `my-feature-lib`"
12 }
13 ],
14 "properties": {
15 "name": {
16 "type": "string",
17 "description": "Target name.",
18 "$default": {
19 "$source": "argv",
20 "index": 0
21 },
22 "x-prompt": "What name would you like to use to invoke the command?"
23 },
24 "project": {
25 "description": "Project name.",
26 "type": "string",
27 "x-prompt": "What project does the target belong to?"
28 },
29 "command": {
30 "description": "Command to run.",
31 "type": "string",
32 "x-prompt": "What command would you like to run?"
33 },
34 "cwd": {
35 "description": "Current working directory of the command.",
36 "type": "string"
37 },
38 "outputs": {
39 "description": "Allows you to specify where the build artifacts are stored. This allows Nx Cloud to pick them up correctly, in the case that the build artifacts are placed somewhere other than the top level dist folder.",
40 "type": "string"
41 },
42 "envFile": {
43 "description": "Env files to be loaded before executing the commands.",
44 "type": "string"
45 }
46 },
47 "required": ["name", "command", "project"]
48}