uniquick 0.1.0 → 0.1.1
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/cli.js +7 -18
- package/package.json +1 -1
package/dist/cli.js
CHANGED
|
@@ -75,16 +75,6 @@ function buildManifest(dir, options = {}) {
|
|
|
75
75
|
walk(dir);
|
|
76
76
|
return { files };
|
|
77
77
|
}
|
|
78
|
-
function checkDeployRoot(dir, root) {
|
|
79
|
-
const realRoot = realpathSync(resolve(root));
|
|
80
|
-
const realDir = realpathSync(resolve(dir));
|
|
81
|
-
if (realDir !== realRoot && !realDir.startsWith(realRoot + sep)) {
|
|
82
|
-
throw new Error(
|
|
83
|
-
`refusing to deploy '${dir}': it is outside the deploy root '${realRoot}'. Set UNIQUICK_DEPLOY_ROOT to a parent directory of your site files to allow it.`
|
|
84
|
-
);
|
|
85
|
-
}
|
|
86
|
-
return realDir;
|
|
87
|
-
}
|
|
88
78
|
function parseArgs(argv) {
|
|
89
79
|
const [command = "", ...rest] = argv;
|
|
90
80
|
const positional = [];
|
|
@@ -231,11 +221,10 @@ var isMain = !!process.argv[1] && import.meta.url === pathToFileURL(resolve(proc
|
|
|
231
221
|
if (isMain) {
|
|
232
222
|
main().catch((e) => fail(e?.message ?? String(e)));
|
|
233
223
|
}
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
};
|
|
224
|
+
|
|
225
|
+
// entries/cli.ts
|
|
226
|
+
main().catch((e) => {
|
|
227
|
+
const msg = e instanceof Error ? e.message : String(e);
|
|
228
|
+
console.error(`error: ${msg}`);
|
|
229
|
+
process.exit(1);
|
|
230
|
+
});
|