git-colabor 0.3.1 → 0.3.2
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.cjs +6 -2
- package/dist/index.cjs +6 -2
- package/package.json +1 -1
package/dist/cli.cjs
CHANGED
|
@@ -384,7 +384,10 @@ function run(args, opts) {
|
|
|
384
384
|
child.stderr.on("data", (d) => {
|
|
385
385
|
stderr += d.toString("utf8");
|
|
386
386
|
});
|
|
387
|
-
child.on(
|
|
387
|
+
child.on(
|
|
388
|
+
"error",
|
|
389
|
+
(e) => reject(e.code !== void 0 && CANNOT_START.has(e.code) ? gitNotFound(cmd, e) : e)
|
|
390
|
+
);
|
|
388
391
|
child.on("close", (code) => {
|
|
389
392
|
resolve4({ stdout, stderr, exitCode: code ?? 0 });
|
|
390
393
|
});
|
|
@@ -421,7 +424,7 @@ async function runBin(cmd, args, opts = {}) {
|
|
|
421
424
|
else child.stdin.end();
|
|
422
425
|
});
|
|
423
426
|
}
|
|
424
|
-
var GitError;
|
|
427
|
+
var GitError, CANNOT_START;
|
|
425
428
|
var init_exec = __esm({
|
|
426
429
|
"src/core/git/exec.ts"() {
|
|
427
430
|
init_errors();
|
|
@@ -437,6 +440,7 @@ var init_exec = __esm({
|
|
|
437
440
|
this.stderr = stderr;
|
|
438
441
|
}
|
|
439
442
|
};
|
|
443
|
+
CANNOT_START = /* @__PURE__ */ new Set(["ENOENT", "EACCES", "EPERM", "ENOTDIR"]);
|
|
440
444
|
}
|
|
441
445
|
});
|
|
442
446
|
|
package/dist/index.cjs
CHANGED
|
@@ -157,7 +157,10 @@ function run(args, opts) {
|
|
|
157
157
|
child.stderr.on("data", (d) => {
|
|
158
158
|
stderr += d.toString("utf8");
|
|
159
159
|
});
|
|
160
|
-
child.on(
|
|
160
|
+
child.on(
|
|
161
|
+
"error",
|
|
162
|
+
(e) => reject(e.code !== void 0 && CANNOT_START.has(e.code) ? gitNotFound(cmd, e) : e)
|
|
163
|
+
);
|
|
161
164
|
child.on("close", (code) => {
|
|
162
165
|
resolve4({ stdout, stderr, exitCode: code ?? 0 });
|
|
163
166
|
});
|
|
@@ -194,7 +197,7 @@ async function runBin(cmd, args, opts = {}) {
|
|
|
194
197
|
else child.stdin.end();
|
|
195
198
|
});
|
|
196
199
|
}
|
|
197
|
-
exports.GitError = void 0;
|
|
200
|
+
exports.GitError = void 0; var CANNOT_START;
|
|
198
201
|
var init_exec = __esm({
|
|
199
202
|
"src/core/git/exec.ts"() {
|
|
200
203
|
init_errors();
|
|
@@ -210,6 +213,7 @@ var init_exec = __esm({
|
|
|
210
213
|
this.stderr = stderr;
|
|
211
214
|
}
|
|
212
215
|
};
|
|
216
|
+
CANNOT_START = /* @__PURE__ */ new Set(["ENOENT", "EACCES", "EPERM", "ENOTDIR"]);
|
|
213
217
|
}
|
|
214
218
|
});
|
|
215
219
|
|