@tywalk/pcf-helper-run 1.6.0 → 1.7.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/README.md +38 -0
- package/dist/index.js +43 -1
- package/dist/package.json +2 -2
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -143,8 +143,46 @@ pcf-helper-run profile list
|
|
|
143
143
|
pcf-helper-run profile show prod
|
|
144
144
|
pcf-helper-run profile current
|
|
145
145
|
pcf-helper-run profile paths
|
|
146
|
+
|
|
147
|
+
# Create a profile without editing JSON (see below for the full flag list)
|
|
148
|
+
pcf-helper-run profile init dev \
|
|
149
|
+
--environment MyDevOrg \
|
|
150
|
+
--publisher-name "Tyler W" \
|
|
151
|
+
--publisher-prefix tyw \
|
|
152
|
+
--path ./MySolution \
|
|
153
|
+
--set-default \
|
|
154
|
+
--no-interactive
|
|
146
155
|
```
|
|
147
156
|
|
|
157
|
+
### Creating a profile from the CLI
|
|
158
|
+
|
|
159
|
+
`profile init <name>` creates or updates a profile without hand-editing
|
|
160
|
+
`pcf-helper.config.json`. Project-level by default; pass `--global` to write to
|
|
161
|
+
`~/.pcf-helper/config.json` (parent directory is created on first use).
|
|
162
|
+
|
|
163
|
+
Interactive by default — each missing field prompts at the terminal, pre-filled
|
|
164
|
+
with whatever you passed as a flag. Pass `--no-interactive` to skip the prompts
|
|
165
|
+
entirely and write only what was supplied.
|
|
166
|
+
|
|
167
|
+
| Flag | Description |
|
|
168
|
+
|------|-------------|
|
|
169
|
+
| `-e, --environment <env>` | Dataverse environment name |
|
|
170
|
+
| `--publisher-name <name>` | Publisher display name |
|
|
171
|
+
| `--publisher-prefix <prefix>` | Publisher prefix (2-8 chars) |
|
|
172
|
+
| `-p, --path <path>` | Path to PCF solution folder |
|
|
173
|
+
| `--template <template>` | `field` or `dataset` |
|
|
174
|
+
| `--framework <framework>` | `none` or `react` |
|
|
175
|
+
| `--session-url <url>` | Session: remote environment URL |
|
|
176
|
+
| `--session-script <path>` | Session: remote script to intercept |
|
|
177
|
+
| `--session-bundle <path>` | Session: local bundle path |
|
|
178
|
+
| `-g, --global` | Write to `~/.pcf-helper/config.json` |
|
|
179
|
+
| `-d, --set-default` | Also set `defaultProfile: <name>` |
|
|
180
|
+
| `-f, --force` | Overwrite an existing profile of the same name |
|
|
181
|
+
| `--no-interactive` | Skip prompts; only use passed flags |
|
|
182
|
+
|
|
183
|
+
The write is atomic (temp file + rename), so an interrupted run never corrupts
|
|
184
|
+
your config.
|
|
185
|
+
|
|
148
186
|
## 📖 Detailed Command Reference
|
|
149
187
|
|
|
150
188
|
### 🏗️ init - Initialize New Project
|
package/dist/index.js
CHANGED
|
@@ -398,4 +398,46 @@ profileCmd
|
|
|
398
398
|
console.log(`project: ${projectPath}`);
|
|
399
399
|
console.log(`loaded: ${sources.length ? sources.join(', ') : '(none)'}`);
|
|
400
400
|
});
|
|
401
|
-
|
|
401
|
+
profileCmd
|
|
402
|
+
.command('init <name>')
|
|
403
|
+
.description('create a new profile in pcf-helper.config.json (project or global)')
|
|
404
|
+
.option('-e, --environment <env>', 'Dataverse environment name')
|
|
405
|
+
.option('--publisher-name <name>', 'publisher display name')
|
|
406
|
+
.option('--publisher-prefix <prefix>', 'publisher prefix (2-8 chars)')
|
|
407
|
+
.option('-p, --path <path>', 'path to PCF solution folder')
|
|
408
|
+
.option('--template <template>', 'control template (field|dataset)')
|
|
409
|
+
.option('--framework <framework>', 'rendering framework (none|react)')
|
|
410
|
+
.option('--session-url <url>', 'session: remote environment URL')
|
|
411
|
+
.option('--session-script <path>', 'session: remote script to intercept')
|
|
412
|
+
.option('--session-bundle <path>', 'session: local bundle path')
|
|
413
|
+
.option('-g, --global', 'write to ~/.pcf-helper/config.json instead of project-level')
|
|
414
|
+
.option('-d, --set-default', 'set this profile as the defaultProfile')
|
|
415
|
+
.option('-f, --force', 'overwrite an existing profile of the same name')
|
|
416
|
+
.option('--no-interactive', 'skip prompts for missing fields')
|
|
417
|
+
.action((name, flags) => __awaiter(void 0, void 0, void 0, function* () {
|
|
418
|
+
const options = {
|
|
419
|
+
name,
|
|
420
|
+
environment: flags.environment,
|
|
421
|
+
publisherName: flags.publisherName,
|
|
422
|
+
publisherPrefix: flags.publisherPrefix,
|
|
423
|
+
path: flags.path,
|
|
424
|
+
template: flags.template,
|
|
425
|
+
framework: flags.framework,
|
|
426
|
+
sessionUrl: flags.sessionUrl,
|
|
427
|
+
sessionScript: flags.sessionScript,
|
|
428
|
+
sessionBundle: flags.sessionBundle,
|
|
429
|
+
global: !!flags.global,
|
|
430
|
+
setDefault: !!flags.setDefault,
|
|
431
|
+
force: !!flags.force,
|
|
432
|
+
nonInteractive: flags.interactive === false,
|
|
433
|
+
};
|
|
434
|
+
try {
|
|
435
|
+
yield (0, pcf_helper_1.runProfileInit)(options);
|
|
436
|
+
}
|
|
437
|
+
catch (e) {
|
|
438
|
+
const message = e instanceof Error ? e.message : String(e);
|
|
439
|
+
console.error(`Error: ${message}`);
|
|
440
|
+
process.exit(1);
|
|
441
|
+
}
|
|
442
|
+
}));
|
|
443
|
+
commander_1.program.parseAsync();
|
package/dist/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tywalk/pcf-helper-run",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.6.0",
|
|
4
4
|
"description": "Unified CLI interface for Power Platform Component Framework (PCF) development — init, build, import, deploy, and manage PCF controls in Dataverse.",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "./types/",
|
|
@@ -52,7 +52,7 @@
|
|
|
52
52
|
},
|
|
53
53
|
"dependencies": {
|
|
54
54
|
"@tywalk/color-logger": "^1.0.3",
|
|
55
|
-
"@tywalk/pcf-helper": "^1.
|
|
55
|
+
"@tywalk/pcf-helper": "^1.16.0"
|
|
56
56
|
},
|
|
57
57
|
"devDependencies": {
|
|
58
58
|
"@semantic-release/git": "^10.0.1",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tywalk/pcf-helper-run",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.7.0",
|
|
4
4
|
"description": "Unified CLI interface for Power Platform Component Framework (PCF) development — init, build, import, deploy, and manage PCF controls in Dataverse.",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "./types/",
|
|
@@ -52,7 +52,7 @@
|
|
|
52
52
|
},
|
|
53
53
|
"dependencies": {
|
|
54
54
|
"@tywalk/color-logger": "^1.0.3",
|
|
55
|
-
"@tywalk/pcf-helper": "^1.
|
|
55
|
+
"@tywalk/pcf-helper": "^1.16.0"
|
|
56
56
|
},
|
|
57
57
|
"devDependencies": {
|
|
58
58
|
"@semantic-release/git": "^10.0.1",
|