@super-one/cli 0.53.11-alpha → 0.54.0-alpha
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/MANIFEST.json +2 -2
- package/lib/cli.mjs +11 -5
- package/package.json +1 -1
package/MANIFEST.json
CHANGED
package/lib/cli.mjs
CHANGED
|
@@ -61519,8 +61519,8 @@ import { fileURLToPath } from "node:url";
|
|
|
61519
61519
|
function resolveCliReleaseVersion() {
|
|
61520
61520
|
const fromEnv = process.env.SUPERONE_CLI_VERSION?.trim();
|
|
61521
61521
|
if (fromEnv) return fromEnv;
|
|
61522
|
-
if ("0.
|
|
61523
|
-
return "0.
|
|
61522
|
+
if ("0.54.0-alpha".trim()) {
|
|
61523
|
+
return "0.54.0-alpha".trim();
|
|
61524
61524
|
}
|
|
61525
61525
|
const fromDist = readDistManifestVersion();
|
|
61526
61526
|
if (fromDist) return fromDist;
|
|
@@ -63473,6 +63473,12 @@ function validateCloneRemoteUrl(url2) {
|
|
|
63473
63473
|
|
|
63474
63474
|
// ../../packages/shared/src/git-clone.ts
|
|
63475
63475
|
var CLONE_TIMEOUT_MS = 15 * 60 * 1e3;
|
|
63476
|
+
function buildCloneArgs(input, destinationPath) {
|
|
63477
|
+
const args = ["clone"];
|
|
63478
|
+
if (input.shallow) args.push("--depth=1");
|
|
63479
|
+
args.push("--", input.remoteUrl.trim(), destinationPath);
|
|
63480
|
+
return args;
|
|
63481
|
+
}
|
|
63476
63482
|
function invalid(message) {
|
|
63477
63483
|
return Object.assign(new Error(message), { code: "invalid_argument" });
|
|
63478
63484
|
}
|
|
@@ -63502,8 +63508,7 @@ async function cloneRepository(input) {
|
|
|
63502
63508
|
await new Promise((resolvePromise, reject) => {
|
|
63503
63509
|
execFile(
|
|
63504
63510
|
"git",
|
|
63505
|
-
|
|
63506
|
-
["clone", "--", input.remoteUrl.trim(), destination.path],
|
|
63511
|
+
buildCloneArgs(input, destination.path),
|
|
63507
63512
|
{
|
|
63508
63513
|
cwd: parent,
|
|
63509
63514
|
timeout: CLONE_TIMEOUT_MS,
|
|
@@ -66935,7 +66940,8 @@ async function handleGitClone(payload, ctx) {
|
|
|
66935
66940
|
const cloned = await cloneRepository({
|
|
66936
66941
|
remoteUrl: String(p2.remoteUrl ?? ""),
|
|
66937
66942
|
parentPath: expandHostPath(String(p2.parentPath ?? "")),
|
|
66938
|
-
directoryName: typeof p2.directoryName === "string" ? p2.directoryName : void 0
|
|
66943
|
+
directoryName: typeof p2.directoryName === "string" ? p2.directoryName : void 0,
|
|
66944
|
+
shallow: p2.shallow === true
|
|
66939
66945
|
});
|
|
66940
66946
|
return { result: ctx.projects.open(cloned.path, cloned.name) };
|
|
66941
66947
|
} catch (err) {
|
package/package.json
CHANGED