sf-decomposer 6.27.0 → 6.29.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/CHANGELOG.md +14 -0
- package/README.md +23 -3
- package/lib/commands/decomposer/decompose.d.ts +1 -0
- package/lib/commands/decomposer/decompose.js +6 -0
- package/lib/commands/decomposer/decompose.js.map +1 -1
- package/lib/core/decomposeMetadataTypes.js +17 -1
- package/lib/core/decomposeMetadataTypes.js.map +1 -1
- package/lib/helpers/types.d.ts +2 -0
- package/lib/hooks/scopedPostRetrieve.js +1 -0
- package/lib/hooks/scopedPostRetrieve.js.map +1 -1
- package/lib/service/core/updateForceignore.d.ts +6 -0
- package/lib/service/core/updateForceignore.js +51 -0
- package/lib/service/core/updateForceignore.js.map +1 -0
- package/messages/decomposer.decompose.md +4 -0
- package/oclif.manifest.json +8 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -5,6 +5,20 @@
|
|
|
5
5
|
|
|
6
6
|
All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
|
|
7
7
|
|
|
8
|
+
## [6.29.0](https://github.com/mcarvin8/sf-decomposer/compare/v6.28.0...v6.29.0) (2026-06-09)
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
### Features
|
|
12
|
+
|
|
13
|
+
* **updateForceignore:** add support for bots ([#482](https://github.com/mcarvin8/sf-decomposer/issues/482)) ([17d40d4](https://github.com/mcarvin8/sf-decomposer/commit/17d40d4321ed9f37cd9fc83b168fbdb915593b29))
|
|
14
|
+
|
|
15
|
+
## [6.28.0](https://github.com/mcarvin8/sf-decomposer/compare/v6.27.0...v6.28.0) (2026-06-09)
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
### Features
|
|
19
|
+
|
|
20
|
+
* **decompose:** add --update-forceignore flag to auto-patch .forceignore ([#480](https://github.com/mcarvin8/sf-decomposer/issues/480)) ([975ee2a](https://github.com/mcarvin8/sf-decomposer/commit/975ee2abb26f028669305641509e0553663cc405))
|
|
21
|
+
|
|
8
22
|
## [6.27.0](https://github.com/mcarvin8/sf-decomposer/compare/v6.26.0...v6.27.0) (2026-06-04)
|
|
9
23
|
|
|
10
24
|
|
package/README.md
CHANGED
|
@@ -69,7 +69,13 @@ sf plugins install sf-decomposer@x.y.z
|
|
|
69
69
|
|
|
70
70
|
**Required.** The Salesforce CLI must ignore decomposed files or `sf` commands will fail. Configure this before running any decompose or retrieve commands.
|
|
71
71
|
|
|
72
|
-
|
|
72
|
+
**Option A — Automatic (recommended):** Pass `--update-forceignore` on your first `sf decomposer decompose` run. The plugin appends type-level wildcard patterns to `.forceignore` — one ignore pattern for decomposed pieces and one negation to re-allow the original metadata file — creating the file if it doesn't exist. Subsequent runs only add new entries; existing ones are never duplicated.
|
|
73
|
+
|
|
74
|
+
```bash
|
|
75
|
+
sf decomposer decompose -m "flow" -m "permissionset" --postpurge --update-forceignore
|
|
76
|
+
```
|
|
77
|
+
|
|
78
|
+
**Option B — Manual:** Copy the [sample .forceignore](https://raw.githubusercontent.com/mcarvin8/sf-decomposer/main/examples/.forceignore) into your project root and adjust the extension patterns for your chosen format (`.xml`, `.json`, `.yaml`, etc.).
|
|
73
79
|
|
|
74
80
|
### 4. Configure Hooks (Recommended)
|
|
75
81
|
|
|
@@ -90,6 +96,7 @@ Add `.sfdecomposer.config.json` to your project root. Copy and customize one of
|
|
|
90
96
|
| `decomposedFormat` | No | `xml`, `json`, `json5`, or `yaml` (default: xml). |
|
|
91
97
|
| `strategy` | No | `unique-id` \| `grouped-by-tag` (default: unique-id). |
|
|
92
98
|
| `decomposeNestedPermissions` | No | With `grouped-by-tag`, set `true` to further decompose permission set and muting permission set object/field permissions. |
|
|
99
|
+
| `updateForceignore` | No | Set `true` to automatically add decomposed file paths to `.forceignore` after each hook-triggered decomposition (default: false). |
|
|
93
100
|
| `overrides` | No | Array of per-type and/or per-component overrides. See [Per-Type & Per-Component Overrides](#per-type--per-component-overrides). |
|
|
94
101
|
|
|
95
102
|
---
|
|
@@ -139,7 +146,7 @@ Decomposes metadata in all local package directories (from `sfdx-project.json`)
|
|
|
139
146
|
|
|
140
147
|
```
|
|
141
148
|
USAGE
|
|
142
|
-
$ sf decomposer decompose [-m <value>] [-x <value>] [-f <value>] [-i <value>] [-s <value>] [--prepurge --postpurge -p -c --json]
|
|
149
|
+
$ sf decomposer decompose [-m <value>] [-x <value>] [-f <value>] [-i <value>] [-s <value>] [--prepurge --postpurge -p -c --update-forceignore --json]
|
|
143
150
|
|
|
144
151
|
FLAGS
|
|
145
152
|
-m, --metadata-type=<value> Metadata suffix to process (e.g. flow, labels). Repeatable. Optional when --manifest is provided.
|
|
@@ -151,6 +158,7 @@ FLAGS
|
|
|
151
158
|
--postpurge Remove original metadata files after decomposing [default: false]
|
|
152
159
|
-p, --decompose-nested-permissions With grouped-by-tag, further decompose permission set and muting permission set object/field permissions
|
|
153
160
|
-c, --config Load per-type and per-component overrides from .sfdecomposer.config.json in the repo root. Only the "overrides" array is consumed. [default: false]
|
|
161
|
+
--update-forceignore Automatically add decomposed file paths to .forceignore after successful decomposition [default: false]
|
|
154
162
|
|
|
155
163
|
GLOBAL FLAGS
|
|
156
164
|
--json Output as JSON.
|
|
@@ -657,7 +665,9 @@ The post-retrieve hook automatically picks up `overrides` from `.sfdecomposer.co
|
|
|
657
665
|
|
|
658
666
|
#### .forceignore
|
|
659
667
|
|
|
660
|
-
The Salesforce CLI must **ignore** decomposed files and **allow** recomposed files. Use the [sample .forceignore](https://raw.githubusercontent.com/mcarvin8/sf-decomposer/main/examples/.forceignore) and set patterns for the extensions you use (`.xml`, `.json`, `.yaml`, etc.).
|
|
668
|
+
The Salesforce CLI must **ignore** decomposed files and **allow** recomposed files. Use `--update-forceignore` on your first `sf decomposer decompose` run to populate this file automatically, or copy the [sample .forceignore](https://raw.githubusercontent.com/mcarvin8/sf-decomposer/main/examples/.forceignore) and set patterns for the extensions you use (`.xml`, `.json`, `.yaml`, etc.).
|
|
669
|
+
|
|
670
|
+
> **Note:** For each processed type, `--update-forceignore` adds a pattern like `**/flows/**/*.xml` (ignore all decomposed pieces) plus `!**/flows/*.flow-meta.xml` (re-allow the original file). Labels use a flat pattern (`**/labels/*.xml` + `!**/labels/CustomLabels.labels-meta.xml`) since they decompose directly into the type directory. Bots use a component-dir pattern (`**/bots/**/*.xml` + `!**/bots/*/*.bot-meta.xml` + `!**/bots/*/*.botVersion-meta.xml`) to handle nested decomposed files and both original suffixes.
|
|
661
671
|
|
|
662
672
|
#### .sfdecomposerignore
|
|
663
673
|
|
|
@@ -722,10 +732,20 @@ Example `WARN` (CustomApplication where four `actionOverrides` siblings shared t
|
|
|
722
732
|
|
|
723
733
|
Already using `decomposePermissionSetBeta2`, `decomposeCustomLabelsBeta`, or similar flags? See [MIGRATION.md](https://github.com/mcarvin8/sf-decomposer/blob/main/MIGRATION.md) before installing sf-decomposer on that project.
|
|
724
734
|
|
|
735
|
+
---
|
|
736
|
+
|
|
725
737
|
## Contributing
|
|
726
738
|
|
|
727
739
|
Contributions are welcome. See [CONTRIBUTING.md](https://github.com/mcarvin8/sf-decomposer/blob/main/CONTRIBUTING.md).
|
|
728
740
|
|
|
741
|
+
---
|
|
742
|
+
|
|
743
|
+
## Issues
|
|
744
|
+
|
|
745
|
+
Please open an [issue](https://github.com/mcarvin8/sf-decomposer/issues) to report any bugs or suggest new features.
|
|
746
|
+
|
|
747
|
+
---
|
|
748
|
+
|
|
729
749
|
## License
|
|
730
750
|
|
|
731
751
|
[MIT](https://raw.githubusercontent.com/mcarvin8/sf-decomposer/main/LICENSE.md)
|
|
@@ -14,6 +14,7 @@ export default class DecomposerDecompose extends SfCommand<DecomposerResult> {
|
|
|
14
14
|
strategy: import("@oclif/core/interfaces").OptionFlag<string, import("@oclif/core/interfaces").CustomOptions>;
|
|
15
15
|
'decompose-nested-permissions': import("@oclif/core/interfaces").BooleanFlag<boolean>;
|
|
16
16
|
config: import("@oclif/core/interfaces").BooleanFlag<boolean>;
|
|
17
|
+
'update-forceignore': import("@oclif/core/interfaces").BooleanFlag<boolean>;
|
|
17
18
|
};
|
|
18
19
|
run(): Promise<DecomposerResult>;
|
|
19
20
|
}
|
|
@@ -67,6 +67,11 @@ export default class DecomposerDecompose extends SfCommand {
|
|
|
67
67
|
required: false,
|
|
68
68
|
default: false,
|
|
69
69
|
}),
|
|
70
|
+
'update-forceignore': Flags.boolean({
|
|
71
|
+
summary: messages.getMessage('flags.update-forceignore.summary'),
|
|
72
|
+
required: false,
|
|
73
|
+
default: false,
|
|
74
|
+
}),
|
|
70
75
|
};
|
|
71
76
|
async run() {
|
|
72
77
|
const { flags } = await this.parse(DecomposerDecompose);
|
|
@@ -84,6 +89,7 @@ export default class DecomposerDecompose extends SfCommand {
|
|
|
84
89
|
decomposeNestedPerms: flags['decompose-nested-permissions'],
|
|
85
90
|
manifest: flags['manifest'],
|
|
86
91
|
overrides,
|
|
92
|
+
updateForceignore: flags['update-forceignore'],
|
|
87
93
|
log: this.log.bind(this),
|
|
88
94
|
});
|
|
89
95
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"decompose.js","sourceRoot":"","sources":["../../../src/commands/decomposer/decompose.ts"],"names":[],"mappings":"AAAA,YAAY,CAAC;AAEb,OAAO,EAAE,SAAS,EAAE,KAAK,EAAE,MAAM,6BAA6B,CAAC;AAC/D,OAAO,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAE5C,OAAO,EAAE,qBAAqB,EAAE,qBAAqB,EAAE,MAAM,4BAA4B,CAAC;AAC1F,OAAO,EAAE,sBAAsB,EAAE,MAAM,sCAAsC,CAAC;AAC9E,OAAO,EAAE,uBAAuB,EAAE,wBAAwB,EAAE,MAAM,kCAAkC,CAAC;AAGrG,QAAQ,CAAC,kCAAkC,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AAC7D,MAAM,QAAQ,GAAG,QAAQ,CAAC,YAAY,CAAC,eAAe,EAAE,s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EAAE,KAAK,CAAC,eAAe,CAAC;YACrC,QAAQ,EAAE,KAAK,CAAC,UAAU,CAAC;YAC3B,SAAS,EAAE,KAAK,CAAC,WAAW,CAAC;YAC7B,MAAM,EAAE,KAAK,CAAC,QAAQ,CAAC;YACvB,UAAU,EAAE,KAAK,CAAC,0BAA0B,CAAC;YAC7C,QAAQ,EAAE,KAAK,CAAC,UAAU,CAAC;YAC3B,oBAAoB,EAAE,KAAK,CAAC,8BAA8B,CAAC;YAC3D,QAAQ,EAAE,KAAK,CAAC,UAAU,CAAC;YAC3B,SAAS;YACT,iBAAiB,EAAE,KAAK,CAAC,oBAAoB,CAAC;YAC9C,GAAG,EAAE,IAAI,CAAC,GAAG,CAAC,IAAI,CAAC,IAAI,CAAC;SACzB,CAAC,CAAC;IACL,CAAC"}
|
|
@@ -1,12 +1,14 @@
|
|
|
1
1
|
'use strict';
|
|
2
|
+
import { dirname, basename } from 'node:path';
|
|
2
3
|
import { getRegistryValuesBySuffix } from '../metadata/getRegistryValuesBySuffix.js';
|
|
3
4
|
import { parseManifest } from '../metadata/parseManifest.js';
|
|
4
5
|
import { decomposeFileHandler } from '../service/decompose/decomposeFileHandler.js';
|
|
5
6
|
import { CONCURRENCY_LIMITS } from '../helpers/constants.js';
|
|
6
7
|
import { pLimit } from '../helpers/pLimit.js';
|
|
7
8
|
import { resolveDecomposeOptionsForType } from '../helpers/configOverrides.js';
|
|
9
|
+
import { updateForceignoreFile } from '../service/core/updateForceignore.js';
|
|
8
10
|
export async function decomposeMetadataTypes(options) {
|
|
9
|
-
const { metadataTypes, prepurge, postpurge, format, ignoreDirs, strategy, decomposeNestedPerms, manifest, overrides, log, repoRoot, } = options;
|
|
11
|
+
const { metadataTypes, prepurge, postpurge, format, ignoreDirs, strategy, decomposeNestedPerms, manifest, overrides, updateForceignore, log, repoRoot, } = options;
|
|
10
12
|
let manifestFilter;
|
|
11
13
|
let effectiveTypes;
|
|
12
14
|
if (manifest) {
|
|
@@ -36,6 +38,8 @@ export async function decomposeMetadataTypes(options) {
|
|
|
36
38
|
// Limit concurrent metadata type processing to prevent file system overload
|
|
37
39
|
const limit = pLimit(CONCURRENCY_LIMITS.METADATA_TYPES);
|
|
38
40
|
const processed = [];
|
|
41
|
+
const processedMeta = [];
|
|
42
|
+
let effectiveRepoRoot;
|
|
39
43
|
const tasks = effectiveTypes.map((metadataType) => limit(async () => {
|
|
40
44
|
const manifestXmlPaths = manifestFilter?.parentXmlsBySuffix.get(metadataType);
|
|
41
45
|
// Type-scope resolved options serve as the base for component-scope resolution further
|
|
@@ -59,9 +63,21 @@ export async function decomposeMetadataTypes(options) {
|
|
|
59
63
|
}
|
|
60
64
|
await decomposeFileHandler(metaAttributes, typeResolved, ignorePath, overrides, manifestXmlPaths);
|
|
61
65
|
processed.push(metadataType);
|
|
66
|
+
if (updateForceignore) {
|
|
67
|
+
processedMeta.push({
|
|
68
|
+
directoryName: basename(metaAttributes.metadataPaths[0]),
|
|
69
|
+
metaSuffix: metaAttributes.metaSuffix,
|
|
70
|
+
format: typeResolved.format,
|
|
71
|
+
});
|
|
72
|
+
effectiveRepoRoot ??= dirname(ignorePath);
|
|
73
|
+
}
|
|
62
74
|
log(`All metadata files have been decomposed for the metadata type: ${metadataType}`);
|
|
63
75
|
}));
|
|
64
76
|
await Promise.all(tasks);
|
|
77
|
+
if (updateForceignore && processedMeta.length > 0 && effectiveRepoRoot) {
|
|
78
|
+
await updateForceignoreFile(processedMeta, effectiveRepoRoot);
|
|
79
|
+
log('Updated .forceignore with decomposed file paths.');
|
|
80
|
+
}
|
|
65
81
|
return { metadata: processed };
|
|
66
82
|
}
|
|
67
83
|
//# sourceMappingURL=decomposeMetadataTypes.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"decomposeMetadataTypes.js","sourceRoot":"","sources":["../../src/core/decomposeMetadataTypes.ts"],"names":[],"mappings":"AAAA,YAAY,CAAC;AAEb,OAAO,EAAE,yBAAyB,EAAE,MAAM,0CAA0C,C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C,CAAC;IACxF,CAAC,CAAC,CACH,CAAC;IAEF,MAAM,OAAO,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC;IAEzB,IAAI,iBAAiB,IAAI,aAAa,CAAC,MAAM,GAAG,CAAC,IAAI,iBAAiB,EAAE,CAAC;QACvE,MAAM,qBAAqB,CAAC,aAAa,EAAE,iBAAiB,CAAC,CAAC;QAC9D,GAAG,CAAC,kDAAkD,CAAC,CAAC;IAC1D,CAAC;IAED,OAAO,EAAE,QAAQ,EAAE,SAAS,EAAE,CAAC;AACjC,CAAC"}
|
package/lib/helpers/types.d.ts
CHANGED
|
@@ -48,6 +48,7 @@ export type ConfigFile = {
|
|
|
48
48
|
ignorePackageDirectories: string;
|
|
49
49
|
strategy: string;
|
|
50
50
|
decomposeNestedPermissions: boolean;
|
|
51
|
+
updateForceignore?: boolean;
|
|
51
52
|
manifest?: string;
|
|
52
53
|
overrides?: DecomposerOverride[];
|
|
53
54
|
};
|
|
@@ -85,6 +86,7 @@ export type DecomposeOptions = {
|
|
|
85
86
|
decomposeNestedPerms: boolean;
|
|
86
87
|
manifest?: string;
|
|
87
88
|
overrides?: DecomposerOverride[];
|
|
89
|
+
updateForceignore?: boolean;
|
|
88
90
|
log: (msg: string) => void;
|
|
89
91
|
repoRoot?: string;
|
|
90
92
|
};
|
|
@@ -31,6 +31,7 @@ function buildDecomposeOptions(configFile, log) {
|
|
|
31
31
|
ignoreDirs,
|
|
32
32
|
strategy: configFile.strategy || 'unique-id',
|
|
33
33
|
decomposeNestedPerms: configFile.decomposeNestedPermissions || false,
|
|
34
|
+
updateForceignore: configFile.updateForceignore ?? false,
|
|
34
35
|
manifest: manifest.trim() !== '' ? manifest.trim() : undefined,
|
|
35
36
|
overrides: configFile.overrides,
|
|
36
37
|
log,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"scopedPostRetrieve.js","sourceRoot":"","sources":["../../src/hooks/scopedPostRetrieve.ts"],"names":[],"mappings":"AAAA,YAAY,C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ACD,MAAM,EAAE,QAAQ,EAAE,GAAG,MAAM,WAAW,EAAE,CAAC;IACzC,IAAI,CAAC,QAAQ,EAAE,CAAC;QACd,OAAO;IACT,CAAC;IACD,MAAM,UAAU,GAAG,OAAO,CAAC,QAAQ,EAAE,gBAAgB,CAAC,CAAC;IAEvD,IAAI,UAAsB,CAAC;IAC3B,IAAI,CAAC;QACH,MAAM,UAAU,GAAW,MAAM,QAAQ,CAAC,UAAU,EAAE,OAAO,CAAC,CAAC;QAC/D,UAAU,GAAG,IAAI,CAAC,KAAK,CAAC,UAAU,CAAe,CAAC;IACpD,CAAC;IAAC,OAAO,KAAK,EAAE,CAAC;QACf,OAAO;IACT,CAAC;IAED,MAAM,gBAAgB,GAAG,qBAAqB,CAAC,UAAU,EAAE,CAAC,GAAW,EAAE,EAAE;QACzE,IAAI,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;IAChB,CAAC,CAAC,CAAC;IACH,IAAI,CAAC,gBAAgB;QAAE,OAAO;IAE9B,MAAM,sBAAsB,CAAC,gBAAgB,CAAC,CAAC;AACjD,CAAC,CAAC"}
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
import { join } from 'node:path';
|
|
3
|
+
import { readFile, writeFile } from 'node:fs/promises';
|
|
4
|
+
function buildPatterns(directoryName, metaSuffix, format) {
|
|
5
|
+
if (metaSuffix === 'labels') {
|
|
6
|
+
// Labels decompose to flat files in the labels dir — one level deep is enough.
|
|
7
|
+
// Allow only the original monolithic file; all individual label files stay ignored.
|
|
8
|
+
return [`**/${directoryName}/*.${format}`, `!**/${directoryName}/CustomLabels.labels-meta.xml`];
|
|
9
|
+
}
|
|
10
|
+
if (metaSuffix === 'bot') {
|
|
11
|
+
// Bots have component dirs at bots/BotName/ containing decomposed pieces; originals are
|
|
12
|
+
// BotName.bot-meta.xml and BotName.botVersion-meta.xml at that level.
|
|
13
|
+
return [
|
|
14
|
+
`**/${directoryName}/**/*.${format}`,
|
|
15
|
+
`!**/${directoryName}/*/*.bot-meta.xml`,
|
|
16
|
+
`!**/${directoryName}/*/*.botVersion-meta.xml`,
|
|
17
|
+
];
|
|
18
|
+
}
|
|
19
|
+
// General case: ignore everything nested inside the type dir (decomposed pieces),
|
|
20
|
+
// then re-allow the original -meta.xml at the root level of that dir.
|
|
21
|
+
return [`**/${directoryName}/**/*.${format}`, `!**/${directoryName}/*.${metaSuffix}-meta.xml`];
|
|
22
|
+
}
|
|
23
|
+
export async function updateForceignoreFile(processedMeta, repoRoot) {
|
|
24
|
+
const forceignorePath = join(repoRoot, '.forceignore');
|
|
25
|
+
let existingContent = '';
|
|
26
|
+
try {
|
|
27
|
+
existingContent = await readFile(forceignorePath, 'utf-8');
|
|
28
|
+
}
|
|
29
|
+
catch {
|
|
30
|
+
// .forceignore doesn't exist yet; start fresh
|
|
31
|
+
}
|
|
32
|
+
// Stryker disable next-line ArrayDeclaration -- empty-array fallback; ["Stryker was here"] is observationally equivalent since no real pattern matches that sentinel
|
|
33
|
+
const existingLines = existingContent ? existingContent.split('\n') : [];
|
|
34
|
+
const existingSet = new Set(existingLines.map((l) => l.trim()));
|
|
35
|
+
const toAdd = [];
|
|
36
|
+
for (const { directoryName, metaSuffix, format } of processedMeta) {
|
|
37
|
+
for (const pattern of buildPatterns(directoryName, metaSuffix, format)) {
|
|
38
|
+
if (!existingSet.has(pattern)) {
|
|
39
|
+
toAdd.push(pattern);
|
|
40
|
+
existingSet.add(pattern);
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
if (toAdd.length === 0)
|
|
45
|
+
return;
|
|
46
|
+
const trimmedContent = existingContent.trimEnd();
|
|
47
|
+
const content = (trimmedContent ? trimmedContent + '\n' : '') + toAdd.join('\n') + '\n';
|
|
48
|
+
// Stryker disable next-line StringLiteral -- encoding sentinel "" is not a meaningful substitution; Node behaviour with invalid encoding is environment-specific
|
|
49
|
+
await writeFile(forceignorePath, content, 'utf-8');
|
|
50
|
+
}
|
|
51
|
+
//# sourceMappingURL=updateForceignore.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"updateForceignore.js","sourceRoot":"","sources":["../../../src/service/core/updateForceignore.ts"],"names":[],"mappings":"AAAA,YAAY,CAAC;AAEb,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AACjC,OAAO,EAAE,QAAQ,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAC;AAQvD,SAAS,aAAa,CAAC,aAAqB,EAAE,UAAkB,EAAE,MAAc;IAC9E,IAAI,UAAU,KAAK,QAAQ,EAAE,CAAC;QAC5B,+EAA+E;QAC/E,oFAAoF;QACpF,OAAO,CAAC,MAAM,aAAa,MAAM,MAAM,EAAE,EAAE,OAAO,aAAa,+BAA+B,CAAC,CAAC;IAClG,CAAC;IACD,IAAI,UAAU,KAAK,KAAK,EAAE,CAAC;QACzB,wFAAwF;QACxF,sEAAsE;QACtE,OAAO;YACL,MAAM,aAAa,SAAS,MAAM,EAAE;YACpC,OAAO,aAAa,mBAAmB;YACvC,OAAO,aAAa,0BAA0B;SAC/C,CAAC;IACJ,CAAC;IACD,kFAAkF;IAClF,sEAAsE;IACtE,OAAO,CAAC,MAAM,aAAa,SAAS,MAAM,EAAE,EAAE,OAAO,aAAa,MAAM,UAAU,WAAW,CAAC,CAAC;AACjG,CAAC;AAED,MAAM,CAAC,KAAK,UAAU,qBAAqB,CAAC,aAA8B,EAAE,QAAgB;IAC1F,MAAM,eAAe,GAAG,IAAI,CAAC,QAAQ,EAAE,cAAc,CAAC,CAAC;IAEvD,IAAI,eAAe,GAAG,EAAE,CAAC;IACzB,IAAI,CAAC;QACH,eAAe,GAAG,MAAM,QAAQ,CAAC,eAAe,EAAE,OAAO,CAAC,CAAC;IAC7D,CAAC;IAAC,MAAM,CAAC;QACP,8CAA8C;IAChD,CAAC;IAED,qKAAqK;IACrK,MAAM,aAAa,GAAG,eAAe,CAAC,CAAC,CAAC,eAAe,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC;IACzE,MAAM,WAAW,GAAG,IAAI,GAAG,CAAC,aAAa,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,IAAI,EAAE,CAAC,CAAC,CAAC;IAEhE,MAAM,KAAK,GAAa,EAAE,CAAC;IAC3B,KAAK,MAAM,EAAE,aAAa,EAAE,UAAU,EAAE,MAAM,EAAE,IAAI,aAAa,EAAE,CAAC;QAClE,KAAK,MAAM,OAAO,IAAI,aAAa,CAAC,aAAa,EAAE,UAAU,EAAE,MAAM,CAAC,EAAE,CAAC;YACvE,IAAI,CAAC,WAAW,CAAC,GAAG,CAAC,OAAO,CAAC,EAAE,CAAC;gBAC9B,KAAK,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;gBACpB,WAAW,CAAC,GAAG,CAAC,OAAO,CAAC,CAAC;YAC3B,CAAC;QACH,CAAC;IACH,CAAC;IAED,IAAI,KAAK,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO;IAE/B,MAAM,cAAc,GAAG,eAAe,CAAC,OAAO,EAAE,CAAC;IACjD,MAAM,OAAO,GAAG,CAAC,cAAc,CAAC,CAAC,CAAC,cAAc,GAAG,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,GAAG,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,GAAG,IAAI,CAAC;IACxF,iKAAiK;IACjK,MAAM,SAAS,CAAC,eAAe,EAAE,OAAO,EAAE,OAAO,CAAC,CAAC;AACrD,CAAC"}
|
|
@@ -52,6 +52,10 @@ Additionally decompose object and field permissions on a permission set when str
|
|
|
52
52
|
|
|
53
53
|
Load per-type and per-component overrides from .sfdecomposer.config.json in the repo root. When set, the file's "overrides" array is applied (format, strategy, decomposeNestedPermissions, uniqueIdElements, prePurge, postPurge per type or per individual component). Other top-level config fields are ignored when invoking the CLI directly.
|
|
54
54
|
|
|
55
|
+
# flags.update-forceignore.summary
|
|
56
|
+
|
|
57
|
+
Automatically add decomposed file paths to .forceignore after successful decomposition.
|
|
58
|
+
|
|
55
59
|
# error.missingMetadataOrManifest
|
|
56
60
|
|
|
57
61
|
Either --metadata-type (-m) or --manifest (-x) must be provided.
|
package/oclif.manifest.json
CHANGED
|
@@ -113,6 +113,13 @@
|
|
|
113
113
|
"summary": "Load per-type and per-component overrides from .sfdecomposer.config.json in the repo root. When set, the file's \"overrides\" array is applied (format, strategy, decomposeNestedPermissions, uniqueIdElements, prePurge, postPurge per type or per individual component). Other top-level config fields are ignored when invoking the CLI directly.",
|
|
114
114
|
"allowNo": false,
|
|
115
115
|
"type": "boolean"
|
|
116
|
+
},
|
|
117
|
+
"update-forceignore": {
|
|
118
|
+
"name": "update-forceignore",
|
|
119
|
+
"required": false,
|
|
120
|
+
"summary": "Automatically add decomposed file paths to .forceignore after successful decomposition.",
|
|
121
|
+
"allowNo": false,
|
|
122
|
+
"type": "boolean"
|
|
116
123
|
}
|
|
117
124
|
},
|
|
118
125
|
"hasDynamicHelp": false,
|
|
@@ -342,5 +349,5 @@
|
|
|
342
349
|
]
|
|
343
350
|
}
|
|
344
351
|
},
|
|
345
|
-
"version": "6.
|
|
352
|
+
"version": "6.29.0"
|
|
346
353
|
}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "sf-decomposer",
|
|
3
3
|
"description": "Split large Salesforce metadata files into version-control-friendly pieces and rebuild deployment-ready files.",
|
|
4
|
-
"version": "6.
|
|
4
|
+
"version": "6.29.0",
|
|
5
5
|
"dependencies": {
|
|
6
6
|
"@oclif/core": "4.11.4",
|
|
7
7
|
"@salesforce/core": "8.26.3",
|