bulkyard 1.2.0 → 1.3.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/lib/commands/bulkyard/extract.js +12 -0
- package/lib/commands/bulkyard/extract.js.map +1 -1
- package/lib/commands/bulkyard/schema.d.ts +19 -0
- package/lib/commands/bulkyard/schema.js +71 -0
- package/lib/commands/bulkyard/schema.js.map +1 -0
- package/lib/core/database.d.ts +9 -0
- package/lib/core/database.js +26 -0
- package/lib/core/database.js.map +1 -1
- package/lib/core/extractor.d.ts +5 -0
- package/lib/core/extractor.js +116 -21
- package/lib/core/extractor.js.map +1 -1
- package/lib/core/schema.d.ts +22 -0
- package/lib/core/schema.js +30 -0
- package/lib/core/schema.js.map +1 -0
- package/messages/bulkyard.extract.md +8 -0
- package/messages/bulkyard.schema.md +39 -0
- package/oclif.lock +108 -249
- package/oclif.manifest.json +93 -1
- package/package.json +3 -2
package/oclif.manifest.json
CHANGED
|
@@ -7,6 +7,7 @@
|
|
|
7
7
|
"examples": [
|
|
8
8
|
"Extract data using a config file:\n<%= config.bin %> <%= command.id %> --target-org myOrg --config-file bulkyard.config.yml",
|
|
9
9
|
"Extract a single object inline:\n<%= config.bin %> <%= command.id %> --target-org myOrg --sobject Account --query \"SELECT Id, Name FROM Account\"",
|
|
10
|
+
"Extract all fields from an object using SELECT \\*:\n<%= config.bin %> <%= command.id %> --target-org myOrg -s Account -q \"SELECT \\* FROM Account\"",
|
|
10
11
|
"Extract inline with a custom database and table name:\n<%= config.bin %> <%= command.id %> --target-org myOrg -s Account -q \"SELECT Id, Name FROM Account\" -d my.db -t Account_Backup"
|
|
11
12
|
],
|
|
12
13
|
"flags": {
|
|
@@ -310,7 +311,98 @@
|
|
|
310
311
|
"bulkyard:load",
|
|
311
312
|
"load:bulkyard"
|
|
312
313
|
]
|
|
314
|
+
},
|
|
315
|
+
"bulkyard:schema": {
|
|
316
|
+
"aliases": [],
|
|
317
|
+
"args": {},
|
|
318
|
+
"description": "Describes one or more Salesforce objects and caches their field metadata into a local SQLite database. Cached schemas allow `bulkyard extract` to expand `SELECT *` queries without making a live describe call.\n\nProvide object names via `--sobjects` (comma-separated) or read them from a `--config-file`.",
|
|
319
|
+
"examples": [
|
|
320
|
+
"Cache schemas for specific objects:\n<%= config.bin %> <%= command.id %> --target-org myOrg --sobjects Account,Contact",
|
|
321
|
+
"Cache schemas for all objects in a config file:\n<%= config.bin %> <%= command.id %> --target-org myOrg --config-file bulkyard.config.yml"
|
|
322
|
+
],
|
|
323
|
+
"flags": {
|
|
324
|
+
"json": {
|
|
325
|
+
"description": "Format output as json.",
|
|
326
|
+
"helpGroup": "GLOBAL",
|
|
327
|
+
"name": "json",
|
|
328
|
+
"allowNo": false,
|
|
329
|
+
"type": "boolean"
|
|
330
|
+
},
|
|
331
|
+
"flags-dir": {
|
|
332
|
+
"helpGroup": "GLOBAL",
|
|
333
|
+
"name": "flags-dir",
|
|
334
|
+
"summary": "Import flag values from a directory.",
|
|
335
|
+
"hasDynamicHelp": false,
|
|
336
|
+
"multiple": false,
|
|
337
|
+
"type": "option"
|
|
338
|
+
},
|
|
339
|
+
"target-org": {
|
|
340
|
+
"char": "o",
|
|
341
|
+
"name": "target-org",
|
|
342
|
+
"noCacheDefault": true,
|
|
343
|
+
"required": true,
|
|
344
|
+
"summary": "Username or alias of the target org. Not required if the `target-org` configuration variable is already set.",
|
|
345
|
+
"hasDynamicHelp": true,
|
|
346
|
+
"multiple": false,
|
|
347
|
+
"type": "option"
|
|
348
|
+
},
|
|
349
|
+
"api-version": {
|
|
350
|
+
"description": "Override the api version used for api requests made by this command",
|
|
351
|
+
"name": "api-version",
|
|
352
|
+
"hasDynamicHelp": false,
|
|
353
|
+
"multiple": false,
|
|
354
|
+
"type": "option"
|
|
355
|
+
},
|
|
356
|
+
"sobjects": {
|
|
357
|
+
"name": "sobjects",
|
|
358
|
+
"summary": "Comma-separated list of Salesforce object API names to describe.",
|
|
359
|
+
"hasDynamicHelp": false,
|
|
360
|
+
"multiple": false,
|
|
361
|
+
"type": "option"
|
|
362
|
+
},
|
|
363
|
+
"config-file": {
|
|
364
|
+
"char": "c",
|
|
365
|
+
"name": "config-file",
|
|
366
|
+
"summary": "Path to the YAML config file (reads object names from it).",
|
|
367
|
+
"hasDynamicHelp": false,
|
|
368
|
+
"multiple": false,
|
|
369
|
+
"type": "option"
|
|
370
|
+
},
|
|
371
|
+
"database": {
|
|
372
|
+
"char": "d",
|
|
373
|
+
"exclusive": [
|
|
374
|
+
"config-file"
|
|
375
|
+
],
|
|
376
|
+
"name": "database",
|
|
377
|
+
"summary": "Path to the SQLite database file.",
|
|
378
|
+
"default": "bulkyard.db",
|
|
379
|
+
"hasDynamicHelp": false,
|
|
380
|
+
"multiple": false,
|
|
381
|
+
"type": "option"
|
|
382
|
+
}
|
|
383
|
+
},
|
|
384
|
+
"hasDynamicHelp": true,
|
|
385
|
+
"hiddenAliases": [],
|
|
386
|
+
"id": "bulkyard:schema",
|
|
387
|
+
"pluginAlias": "bulkyard",
|
|
388
|
+
"pluginName": "bulkyard",
|
|
389
|
+
"pluginType": "core",
|
|
390
|
+
"strict": true,
|
|
391
|
+
"summary": "Cache Salesforce object schemas into a local SQLite database.",
|
|
392
|
+
"enableJsonFlag": true,
|
|
393
|
+
"isESM": true,
|
|
394
|
+
"relativePath": [
|
|
395
|
+
"lib",
|
|
396
|
+
"commands",
|
|
397
|
+
"bulkyard",
|
|
398
|
+
"schema.js"
|
|
399
|
+
],
|
|
400
|
+
"aliasPermutations": [],
|
|
401
|
+
"permutations": [
|
|
402
|
+
"bulkyard:schema",
|
|
403
|
+
"schema:bulkyard"
|
|
404
|
+
]
|
|
313
405
|
}
|
|
314
406
|
},
|
|
315
|
-
"version": "1.
|
|
407
|
+
"version": "1.3.0"
|
|
316
408
|
}
|
package/package.json
CHANGED
|
@@ -1,16 +1,17 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "bulkyard",
|
|
3
3
|
"description": "A Salesforce CLI plugin for bulk data extraction and loading via local SQLite3 databases.",
|
|
4
|
-
"version": "1.
|
|
4
|
+
"version": "1.3.0",
|
|
5
5
|
"dependencies": {
|
|
6
6
|
"@oclif/core": "^4",
|
|
7
7
|
"@salesforce/core": "^8",
|
|
8
8
|
"@salesforce/sf-plugins-core": "^12",
|
|
9
9
|
"better-sqlite3": "^9",
|
|
10
|
+
"csv-parse": "^5",
|
|
10
11
|
"js-yaml": "^4.1.1"
|
|
11
12
|
},
|
|
12
13
|
"devDependencies": {
|
|
13
|
-
"@oclif/plugin-command-snapshot": "^5.
|
|
14
|
+
"@oclif/plugin-command-snapshot": "^5.3.9",
|
|
14
15
|
"@salesforce/cli-plugins-testkit": "^5.3.10",
|
|
15
16
|
"@salesforce/dev-scripts": "^10",
|
|
16
17
|
"@types/better-sqlite3": "^7.6.13",
|