@sanity/pkg-utils 3.3.8 → 4.0.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/dist/_chunks/{build-7mn5THX6.cjs → build-xtvcN4rn.cjs} +50 -61
- package/dist/_chunks/build-xtvcN4rn.cjs.map +1 -0
- package/dist/_chunks/{buildAction-fRHTIDmx.cjs → buildAction-lOl6hAY8.cjs} +5 -3
- package/dist/_chunks/{buildAction-fRHTIDmx.cjs.map → buildAction-lOl6hAY8.cjs.map} +1 -1
- package/dist/_chunks/check-5On74q2h.cjs +222 -0
- package/dist/_chunks/check-5On74q2h.cjs.map +1 -0
- package/dist/_chunks/{checkAction-0xA1q64g.cjs → checkAction-RYG9-Wqo.cjs} +5 -3
- package/dist/_chunks/checkAction-RYG9-Wqo.cjs.map +1 -0
- package/dist/_chunks/{consoleSpy-g4ZadSyB.cjs → consoleSpy-bV4ZI2h8.cjs} +181 -179
- package/dist/_chunks/{consoleSpy-g4ZadSyB.cjs.map → consoleSpy-bV4ZI2h8.cjs.map} +1 -1
- package/dist/_chunks/{handleError-esTdSrHu.cjs → handleError-fVK262CU.cjs} +6 -6
- package/dist/_chunks/handleError-fVK262CU.cjs.map +1 -0
- package/dist/_chunks/index-YSy1xob6.cjs +36038 -0
- package/dist/_chunks/{index-1Mfz_QDA.cjs.map → index-YSy1xob6.cjs.map} +1 -1
- package/dist/_chunks/init-tT7f7xkO.cjs +646 -0
- package/dist/_chunks/{init-U-HiL7BD.cjs.map → init-tT7f7xkO.cjs.map} +1 -1
- package/dist/_chunks/{initAction-QVQEhQh6.cjs → initAction-zkJJWu4U.cjs} +5 -3
- package/dist/_chunks/initAction-zkJJWu4U.cjs.map +1 -0
- package/dist/_chunks/{logger-iA0nC-kL.cjs → logger-c-JGqYo_.cjs} +45 -43
- package/dist/_chunks/logger-c-JGqYo_.cjs.map +1 -0
- package/dist/_chunks/watch-Mo2KRBJf.cjs +226 -0
- package/dist/_chunks/watch-Mo2KRBJf.cjs.map +1 -0
- package/dist/_chunks/{watchAction-JfAFOHP0.cjs → watchAction-7JsrPTEX.cjs} +5 -3
- package/dist/_chunks/watchAction-7JsrPTEX.cjs.map +1 -0
- package/dist/cli.cjs +14 -30
- package/dist/cli.cjs.map +1 -1
- package/dist/index.cjs +11 -10
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +37229 -1530
- package/dist/index.js.map +1 -1
- package/package.json +14 -15
- package/src/node/tasks/rollup/resolveRollupConfig.ts +6 -11
- package/dist/_chunks/build-7mn5THX6.cjs.map +0 -1
- package/dist/_chunks/check-pxYRC97N.cjs +0 -250
- package/dist/_chunks/check-pxYRC97N.cjs.map +0 -1
- package/dist/_chunks/checkAction-0xA1q64g.cjs.map +0 -1
- package/dist/_chunks/handleError-esTdSrHu.cjs.map +0 -1
- package/dist/_chunks/index-1Mfz_QDA.cjs +0 -2159
- package/dist/_chunks/init-U-HiL7BD.cjs +0 -500
- package/dist/_chunks/initAction-QVQEhQh6.cjs.map +0 -1
- package/dist/_chunks/logger-iA0nC-kL.cjs.map +0 -1
- package/dist/_chunks/watch-6xc8QXJF.cjs +0 -233
- package/dist/_chunks/watch-6xc8QXJF.cjs.map +0 -1
- package/dist/_chunks/watchAction-JfAFOHP0.cjs.map +0 -1
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var watch = require('./watch-
|
|
4
|
-
var handleError = require('./handleError-
|
|
3
|
+
var watch = require('./watch-Mo2KRBJf.cjs');
|
|
4
|
+
var handleError = require('./handleError-fVK262CU.cjs');
|
|
5
|
+
|
|
5
6
|
async function watchAction(options) {
|
|
6
7
|
try {
|
|
7
8
|
await watch.watch({
|
|
@@ -13,5 +14,6 @@ async function watchAction(options) {
|
|
|
13
14
|
handleError.handleError(err);
|
|
14
15
|
}
|
|
15
16
|
}
|
|
17
|
+
|
|
16
18
|
exports.watchAction = watchAction;
|
|
17
|
-
//# sourceMappingURL=watchAction-
|
|
19
|
+
//# sourceMappingURL=watchAction-7JsrPTEX.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"watchAction-7JsrPTEX.cjs","sources":["../../src/cli/watchAction.ts"],"sourcesContent":["import {watch} from '../node/watch'\nimport {handleError} from './handleError'\n\nexport async function watchAction(options: {strict?: boolean; tsconfig?: string}): Promise<void> {\n try {\n await watch({\n cwd: process.cwd(),\n strict: options.strict,\n tsconfig: options.tsconfig,\n })\n } catch (err) {\n handleError(err)\n }\n}\n"],"names":["watch","handleError"],"mappings":";;;;;AAGA,eAAsB,YAAY,OAA+D,EAAA;AAC/F,EAAI,IAAA;AACF,IAAA,MAAMA,WAAM,CAAA;AAAA,MACV,GAAA,EAAK,QAAQ,GAAI,EAAA;AAAA,MACjB,QAAQ,OAAQ,CAAA,MAAA;AAAA,MAChB,UAAU,OAAQ,CAAA,QAAA;AAAA,KACnB,CAAA,CAAA;AAAA,WACM,GAAK,EAAA;AACZ,IAAAC,uBAAA,CAAY,GAAG,CAAA,CAAA;AAAA,GACjB;AACF;;;;"}
|
package/dist/cli.cjs
CHANGED
|
@@ -1,46 +1,30 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
var cac = require('cac');
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
};
|
|
8
|
-
}
|
|
4
|
+
|
|
5
|
+
function _interopDefaultCompat (e) { return e && typeof e === 'object' && 'default' in e ? e : { default: e }; }
|
|
6
|
+
|
|
9
7
|
var cac__default = /*#__PURE__*/_interopDefaultCompat(cac);
|
|
10
|
-
|
|
8
|
+
|
|
9
|
+
var version = "4.0.0";
|
|
10
|
+
|
|
11
11
|
const cli = cac__default.default();
|
|
12
|
-
cli.command("", "Check").alias("check").option("--strict", "Strict mode").option("--tsconfig [tsconfig]", "[string] tsconfig.json").action(async options => {
|
|
13
|
-
const {
|
|
14
|
-
checkAction
|
|
15
|
-
} = await Promise.resolve().then(function () {
|
|
16
|
-
return require('./_chunks/checkAction-0xA1q64g.cjs');
|
|
17
|
-
});
|
|
12
|
+
cli.command("", "Check").alias("check").option("--strict", "Strict mode").option("--tsconfig [tsconfig]", "[string] tsconfig.json").action(async (options) => {
|
|
13
|
+
const { checkAction } = await Promise.resolve().then(function () { return require('./_chunks/checkAction-RYG9-Wqo.cjs'); });
|
|
18
14
|
return checkAction(options);
|
|
19
15
|
});
|
|
20
|
-
cli.command("build", "Build package").option("--emitDeclarationOnly", "Emit d.ts only").option("--strict", "Strict mode").option("--tsconfig [tsconfig]", "[string] tsconfig.json").action(async options => {
|
|
21
|
-
const {
|
|
22
|
-
buildAction
|
|
23
|
-
} = await Promise.resolve().then(function () {
|
|
24
|
-
return require('./_chunks/buildAction-fRHTIDmx.cjs');
|
|
25
|
-
});
|
|
16
|
+
cli.command("build", "Build package").option("--emitDeclarationOnly", "Emit d.ts only").option("--strict", "Strict mode").option("--tsconfig [tsconfig]", "[string] tsconfig.json").action(async (options) => {
|
|
17
|
+
const { buildAction } = await Promise.resolve().then(function () { return require('./_chunks/buildAction-lOl6hAY8.cjs'); });
|
|
26
18
|
return buildAction(options);
|
|
27
19
|
});
|
|
28
|
-
cli.command("init [path]", "Initialize package").action(async p => {
|
|
29
|
-
const {
|
|
30
|
-
initAction
|
|
31
|
-
} = await Promise.resolve().then(function () {
|
|
32
|
-
return require('./_chunks/initAction-QVQEhQh6.cjs');
|
|
33
|
-
});
|
|
20
|
+
cli.command("init [path]", "Initialize package").action(async (p) => {
|
|
21
|
+
const { initAction } = await Promise.resolve().then(function () { return require('./_chunks/initAction-zkJJWu4U.cjs'); });
|
|
34
22
|
return initAction({
|
|
35
23
|
path: p
|
|
36
24
|
});
|
|
37
25
|
});
|
|
38
|
-
cli.command("watch", "Watch package").option("--strict", "Strict mode").option("--tsconfig [tsconfig]", "[string] tsconfig.json").action(async options => {
|
|
39
|
-
const {
|
|
40
|
-
watchAction
|
|
41
|
-
} = await Promise.resolve().then(function () {
|
|
42
|
-
return require('./_chunks/watchAction-JfAFOHP0.cjs');
|
|
43
|
-
});
|
|
26
|
+
cli.command("watch", "Watch package").option("--strict", "Strict mode").option("--tsconfig [tsconfig]", "[string] tsconfig.json").action(async (options) => {
|
|
27
|
+
const { watchAction } = await Promise.resolve().then(function () { return require('./_chunks/watchAction-7JsrPTEX.cjs'); });
|
|
44
28
|
return watchAction(options);
|
|
45
29
|
});
|
|
46
30
|
cli.help();
|
package/dist/cli.cjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cli.cjs","sources":["../src/cli/index.ts"],"sourcesContent":["import cac from 'cac'\n\nimport {version} from '../../package.json'\n\nconst cli = cac()\n\ncli\n .command('', 'Check')\n .alias('check') // alias to align with the action name\n .option('--strict', 'Strict mode')\n .option('--tsconfig [tsconfig]', '[string] tsconfig.json')\n .action(async (options) => {\n const {checkAction} = await import('./checkAction')\n\n return checkAction(options)\n })\n\ncli\n .command('build', 'Build package')\n .option('--emitDeclarationOnly', 'Emit d.ts only')\n .option('--strict', 'Strict mode')\n .option('--tsconfig [tsconfig]', '[string] tsconfig.json')\n .action(async (options) => {\n const {buildAction} = await import('./buildAction')\n\n return buildAction(options)\n })\n\ncli.command('init [path]', 'Initialize package').action(async (p) => {\n const {initAction} = await import('./initAction')\n\n return initAction({\n path: p,\n })\n})\n\ncli\n .command('watch', 'Watch package')\n .option('--strict', 'Strict mode')\n .option('--tsconfig [tsconfig]', '[string] tsconfig.json')\n .action(async (options) => {\n const {watchAction} = await import('./watchAction')\n\n return watchAction(options)\n })\n\n// Display help message when `-h` or `--help` appears\ncli.help()\n\n// Display version number when `-v` or `--version` appears\n// It's also used in help message\ncli.version(version)\n\ncli.parse()\n"],"names":["
|
|
1
|
+
{"version":3,"file":"cli.cjs","sources":["../src/cli/index.ts"],"sourcesContent":["import cac from 'cac'\n\nimport {version} from '../../package.json'\n\nconst cli = cac()\n\ncli\n .command('', 'Check')\n .alias('check') // alias to align with the action name\n .option('--strict', 'Strict mode')\n .option('--tsconfig [tsconfig]', '[string] tsconfig.json')\n .action(async (options) => {\n const {checkAction} = await import('./checkAction')\n\n return checkAction(options)\n })\n\ncli\n .command('build', 'Build package')\n .option('--emitDeclarationOnly', 'Emit d.ts only')\n .option('--strict', 'Strict mode')\n .option('--tsconfig [tsconfig]', '[string] tsconfig.json')\n .action(async (options) => {\n const {buildAction} = await import('./buildAction')\n\n return buildAction(options)\n })\n\ncli.command('init [path]', 'Initialize package').action(async (p) => {\n const {initAction} = await import('./initAction')\n\n return initAction({\n path: p,\n })\n})\n\ncli\n .command('watch', 'Watch package')\n .option('--strict', 'Strict mode')\n .option('--tsconfig [tsconfig]', '[string] tsconfig.json')\n .action(async (options) => {\n const {watchAction} = await import('./watchAction')\n\n return watchAction(options)\n })\n\n// Display help message when `-h` or `--help` appears\ncli.help()\n\n// Display version number when `-v` or `--version` appears\n// It's also used in help message\ncli.version(version)\n\ncli.parse()\n"],"names":["cac"],"mappings":";;;;;;;;;;AAIA,MAAM,MAAMA,oBAAI,EAAA,CAAA;AAEhB,GAAA,CACG,QAAQ,EAAI,EAAA,OAAO,CACnB,CAAA,KAAA,CAAM,OAAO,CACb,CAAA,MAAA,CAAO,UAAY,EAAA,aAAa,EAChC,MAAO,CAAA,uBAAA,EAAyB,wBAAwB,CACxD,CAAA,MAAA,CAAO,OAAO,OAAY,KAAA;AACzB,EAAA,MAAM,EAAC,WAAA,EAAe,GAAA,MAAM,oDAAO,oCAAe,KAAA,CAAA;AAElD,EAAA,OAAO,YAAY,OAAO,CAAA,CAAA;AAC5B,CAAC,CAAA,CAAA;AAEH,GAAA,CACG,QAAQ,OAAS,EAAA,eAAe,EAChC,MAAO,CAAA,uBAAA,EAAyB,gBAAgB,CAChD,CAAA,MAAA,CAAO,UAAY,EAAA,aAAa,EAChC,MAAO,CAAA,uBAAA,EAAyB,wBAAwB,CACxD,CAAA,MAAA,CAAO,OAAO,OAAY,KAAA;AACzB,EAAA,MAAM,EAAC,WAAA,EAAe,GAAA,MAAM,oDAAO,oCAAe,KAAA,CAAA;AAElD,EAAA,OAAO,YAAY,OAAO,CAAA,CAAA;AAC5B,CAAC,CAAA,CAAA;AAEH,GAAA,CAAI,QAAQ,aAAe,EAAA,oBAAoB,CAAE,CAAA,MAAA,CAAO,OAAO,CAAM,KAAA;AACnE,EAAA,MAAM,EAAC,UAAA,EAAc,GAAA,MAAM,oDAAO,mCAAc,KAAA,CAAA;AAEhD,EAAA,OAAO,UAAW,CAAA;AAAA,IAChB,IAAM,EAAA,CAAA;AAAA,GACP,CAAA,CAAA;AACH,CAAC,CAAA,CAAA;AAED,GAAA,CACG,OAAQ,CAAA,OAAA,EAAS,eAAe,CAAA,CAChC,OAAO,UAAY,EAAA,aAAa,CAChC,CAAA,MAAA,CAAO,uBAAyB,EAAA,wBAAwB,CACxD,CAAA,MAAA,CAAO,OAAO,OAAY,KAAA;AACzB,EAAA,MAAM,EAAC,WAAA,EAAe,GAAA,MAAM,oDAAO,oCAAe,KAAA,CAAA;AAElD,EAAA,OAAO,YAAY,OAAO,CAAA,CAAA;AAC5B,CAAC,CAAA,CAAA;AAGH,GAAA,CAAI,IAAK,EAAA,CAAA;AAIT,GAAA,CAAI,QAAQ,OAAO,CAAA,CAAA;AAEnB,GAAA,CAAI,KAAM,EAAA;;"}
|
package/dist/index.cjs
CHANGED
|
@@ -1,18 +1,19 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
Object.defineProperty(exports, '__esModule', {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
var
|
|
7
|
-
var
|
|
8
|
-
var
|
|
9
|
-
var
|
|
10
|
-
var
|
|
11
|
-
var
|
|
12
|
-
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
+
|
|
5
|
+
var build = require('./_chunks/build-xtvcN4rn.cjs');
|
|
6
|
+
var check = require('./_chunks/check-5On74q2h.cjs');
|
|
7
|
+
var consoleSpy = require('./_chunks/consoleSpy-bV4ZI2h8.cjs');
|
|
8
|
+
var logger = require('./_chunks/logger-c-JGqYo_.cjs');
|
|
9
|
+
var init = require('./_chunks/init-tT7f7xkO.cjs');
|
|
10
|
+
var index = require('./_chunks/index-YSy1xob6.cjs');
|
|
11
|
+
var watch = require('./_chunks/watch-Mo2KRBJf.cjs');
|
|
12
|
+
|
|
13
13
|
function defineConfig(configOptions) {
|
|
14
14
|
return configOptions;
|
|
15
15
|
}
|
|
16
|
+
|
|
16
17
|
exports.build = build.build;
|
|
17
18
|
exports.resolveBuildTasks = build.resolveBuildTasks;
|
|
18
19
|
exports.check = check.check;
|
package/dist/index.cjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.cjs","sources":["../src/node/core/config/defineConfig.ts"],"sourcesContent":["import {PkgConfigOptions} from './types'\n\n/** @public */\nexport function defineConfig(configOptions: PkgConfigOptions): PkgConfigOptions {\n return configOptions\n}\n"],"names":[
|
|
1
|
+
{"version":3,"file":"index.cjs","sources":["../src/node/core/config/defineConfig.ts"],"sourcesContent":["import {PkgConfigOptions} from './types'\n\n/** @public */\nexport function defineConfig(configOptions: PkgConfigOptions): PkgConfigOptions {\n return configOptions\n}\n"],"names":[],"mappings":";;;;;;;;;;;;AAGO,SAAS,aAAa,aAAmD,EAAA;AAC9E,EAAO,OAAA,aAAA,CAAA;AACT;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|