@prisma/cli-init 0.0.0-dev.202512162132 → 0.0.0-dev.202512162203
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/{accelerate-7HJZB2GE.js → accelerate-5VID4BSA.js} +1317 -816
- package/dist/{chunk-YTWW6A72.js → chunk-7WBH7PZA.js} +245 -72
- package/dist/index.js +132 -138
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -21,7 +21,7 @@ import {
|
|
|
21
21
|
url,
|
|
22
22
|
withResolvers,
|
|
23
23
|
y
|
|
24
|
-
} from "./chunk-
|
|
24
|
+
} from "./chunk-7WBH7PZA.js";
|
|
25
25
|
import {
|
|
26
26
|
__commonJS,
|
|
27
27
|
__require,
|
|
@@ -47,9 +47,9 @@ var require_polyfills = __commonJS({
|
|
|
47
47
|
}
|
|
48
48
|
if (typeof process.chdir === "function") {
|
|
49
49
|
chdir = process.chdir;
|
|
50
|
-
process.chdir = function(
|
|
50
|
+
process.chdir = function(d) {
|
|
51
51
|
cwd = null;
|
|
52
|
-
chdir.call(process,
|
|
52
|
+
chdir.call(process, d);
|
|
53
53
|
};
|
|
54
54
|
if (Object.setPrototypeOf)
|
|
55
55
|
Object.setPrototypeOf(process.chdir, chdir);
|
|
@@ -794,10 +794,10 @@ var require_graceful_fs = __commonJS({
|
|
|
794
794
|
var retryTimer;
|
|
795
795
|
function resetQueue() {
|
|
796
796
|
var now = Date.now();
|
|
797
|
-
for (var
|
|
798
|
-
if (fs5[gracefulQueue][
|
|
799
|
-
fs5[gracefulQueue][
|
|
800
|
-
fs5[gracefulQueue][
|
|
797
|
+
for (var i3 = 0; i3 < fs5[gracefulQueue].length; ++i3) {
|
|
798
|
+
if (fs5[gracefulQueue][i3].length > 2) {
|
|
799
|
+
fs5[gracefulQueue][i3][3] = now;
|
|
800
|
+
fs5[gracefulQueue][i3][4] = now;
|
|
801
801
|
}
|
|
802
802
|
}
|
|
803
803
|
retry();
|
|
@@ -956,8 +956,8 @@ var require_retry_operation = __commonJS({
|
|
|
956
956
|
var counts = {};
|
|
957
957
|
var mainError = null;
|
|
958
958
|
var mainErrorCount = 0;
|
|
959
|
-
for (var
|
|
960
|
-
var error = this._errors[
|
|
959
|
+
for (var i3 = 0; i3 < this._errors.length; i3++) {
|
|
960
|
+
var error = this._errors[i3];
|
|
961
961
|
var message = error.message;
|
|
962
962
|
var count = (counts[message] || 0) + 1;
|
|
963
963
|
counts[message] = count;
|
|
@@ -1002,14 +1002,14 @@ var require_retry = __commonJS({
|
|
|
1002
1002
|
throw new Error("minTimeout is greater than maxTimeout");
|
|
1003
1003
|
}
|
|
1004
1004
|
var timeouts = [];
|
|
1005
|
-
for (var
|
|
1006
|
-
timeouts.push(this.createTimeout(
|
|
1005
|
+
for (var i3 = 0; i3 < opts.retries; i3++) {
|
|
1006
|
+
timeouts.push(this.createTimeout(i3, opts));
|
|
1007
1007
|
}
|
|
1008
1008
|
if (options && options.forever && !timeouts.length) {
|
|
1009
|
-
timeouts.push(this.createTimeout(
|
|
1009
|
+
timeouts.push(this.createTimeout(i3, opts));
|
|
1010
1010
|
}
|
|
1011
|
-
timeouts.sort(function(
|
|
1012
|
-
return
|
|
1011
|
+
timeouts.sort(function(a, b) {
|
|
1012
|
+
return a - b;
|
|
1013
1013
|
});
|
|
1014
1014
|
return timeouts;
|
|
1015
1015
|
};
|
|
@@ -1032,8 +1032,8 @@ var require_retry = __commonJS({
|
|
|
1032
1032
|
}
|
|
1033
1033
|
}
|
|
1034
1034
|
}
|
|
1035
|
-
for (var
|
|
1036
|
-
var method = methods[
|
|
1035
|
+
for (var i3 = 0; i3 < methods.length; i3++) {
|
|
1036
|
+
var method = methods[i3];
|
|
1037
1037
|
var original = obj[method];
|
|
1038
1038
|
obj[method] = function retryWrapper(original2) {
|
|
1039
1039
|
var op = exports.operation(options);
|
|
@@ -1532,7 +1532,7 @@ var require_lockfile = __commonJS({
|
|
|
1532
1532
|
const options = locks[file].options;
|
|
1533
1533
|
try {
|
|
1534
1534
|
options.fs.rmdirSync(getLockFile(file, options));
|
|
1535
|
-
} catch (
|
|
1535
|
+
} catch (e2) {
|
|
1536
1536
|
}
|
|
1537
1537
|
}
|
|
1538
1538
|
});
|
|
@@ -1653,7 +1653,7 @@ function normalizeWindowsPath(input2 = "") {
|
|
|
1653
1653
|
if (!input2) {
|
|
1654
1654
|
return input2;
|
|
1655
1655
|
}
|
|
1656
|
-
return input2.replace(/\\/g, "/").replace(_DRIVE_LETTER_START_RE, (
|
|
1656
|
+
return input2.replace(/\\/g, "/").replace(_DRIVE_LETTER_START_RE, (r4) => r4.toUpperCase());
|
|
1657
1657
|
}
|
|
1658
1658
|
var _UNC_REGEX = /^[/\\]{2}/;
|
|
1659
1659
|
var _IS_ABSOLUTE_RE = /^[/\\](?![/\\])|^[/\\]{2}(?!\.)|^[A-Za-z]:[/\\]/;
|
|
@@ -1788,9 +1788,9 @@ function filename(path6) {
|
|
|
1788
1788
|
return base.slice(0, separatorIndex);
|
|
1789
1789
|
}
|
|
1790
1790
|
|
|
1791
|
-
// ../../node_modules/.pnpm/get-port-please@3.
|
|
1792
|
-
import { createServer } from "net";
|
|
1793
|
-
import { networkInterfaces } from "os";
|
|
1791
|
+
// ../../node_modules/.pnpm/get-port-please@3.2.0/node_modules/get-port-please/dist/index.mjs
|
|
1792
|
+
import { createServer, Server } from "net";
|
|
1793
|
+
import { networkInterfaces, tmpdir } from "os";
|
|
1794
1794
|
var unsafePorts = /* @__PURE__ */ new Set([
|
|
1795
1795
|
1,
|
|
1796
1796
|
// tcpmux
|
|
@@ -1959,18 +1959,12 @@ function isUnsafePort(port) {
|
|
|
1959
1959
|
function isSafePort(port) {
|
|
1960
1960
|
return !isUnsafePort(port);
|
|
1961
1961
|
}
|
|
1962
|
-
var __defProp = Object.defineProperty;
|
|
1963
|
-
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
1964
|
-
var __publicField = (obj, key, value) => {
|
|
1965
|
-
__defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value);
|
|
1966
|
-
return value;
|
|
1967
|
-
};
|
|
1968
1962
|
var GetPortError = class extends Error {
|
|
1969
1963
|
constructor(message, opts) {
|
|
1970
1964
|
super(message, opts);
|
|
1971
1965
|
this.message = message;
|
|
1972
|
-
__publicField(this, "name", "GetPortError");
|
|
1973
1966
|
}
|
|
1967
|
+
name = "GetPortError";
|
|
1974
1968
|
};
|
|
1975
1969
|
function _log(verbose, message) {
|
|
1976
1970
|
if (verbose) {
|
|
@@ -1981,11 +1975,11 @@ function _generateRange(from, to) {
|
|
|
1981
1975
|
if (to < from) {
|
|
1982
1976
|
return [];
|
|
1983
1977
|
}
|
|
1984
|
-
const
|
|
1978
|
+
const r4 = [];
|
|
1985
1979
|
for (let index = from; index <= to; index++) {
|
|
1986
|
-
|
|
1980
|
+
r4.push(index);
|
|
1987
1981
|
}
|
|
1988
|
-
return
|
|
1982
|
+
return r4;
|
|
1989
1983
|
}
|
|
1990
1984
|
function _tryPort(port, host) {
|
|
1991
1985
|
return new Promise((resolve2) => {
|
|
@@ -2006,7 +2000,8 @@ function _getLocalHosts(additional) {
|
|
|
2006
2000
|
const hosts = new Set(additional);
|
|
2007
2001
|
for (const _interface of Object.values(networkInterfaces())) {
|
|
2008
2002
|
for (const config of _interface || []) {
|
|
2009
|
-
if (config.address && !config.internal && !config.address.startsWith("fe80::")
|
|
2003
|
+
if (config.address && !config.internal && !config.address.startsWith("fe80::") && // Link-Local
|
|
2004
|
+
!config.address.startsWith("169.254")) {
|
|
2010
2005
|
hosts.add(config.address);
|
|
2011
2006
|
}
|
|
2012
2007
|
}
|
|
@@ -2015,9 +2010,9 @@ function _getLocalHosts(additional) {
|
|
|
2015
2010
|
}
|
|
2016
2011
|
async function _findPort(ports, host) {
|
|
2017
2012
|
for (const port of ports) {
|
|
2018
|
-
const
|
|
2019
|
-
if (
|
|
2020
|
-
return
|
|
2013
|
+
const r4 = await _tryPort(port, host);
|
|
2014
|
+
if (r4) {
|
|
2015
|
+
return r4;
|
|
2021
2016
|
}
|
|
2022
2017
|
}
|
|
2023
2018
|
}
|
|
@@ -2047,7 +2042,6 @@ async function getPort(_userOptions = {}) {
|
|
|
2047
2042
|
_userOptions.port || _userOptions.ports?.length || _userOptions.portRange?.length
|
|
2048
2043
|
);
|
|
2049
2044
|
const options = {
|
|
2050
|
-
name: "default",
|
|
2051
2045
|
random: _port === 0,
|
|
2052
2046
|
ports: [],
|
|
2053
2047
|
portRange: [],
|
|
@@ -2151,118 +2145,118 @@ async function checkPort(port, host = process.env.HOST, verbose) {
|
|
|
2151
2145
|
return port;
|
|
2152
2146
|
}
|
|
2153
2147
|
|
|
2154
|
-
// ../../node_modules/.pnpm/remeda@2.
|
|
2155
|
-
|
|
2156
|
-
|
|
2148
|
+
// ../../node_modules/.pnpm/remeda@2.32.0/node_modules/remeda/dist/lazyDataLastImpl-BDhrIOwR.js
|
|
2149
|
+
function e(e2, t6, n3) {
|
|
2150
|
+
let r4 = (n4) => e2(n4, ...t6);
|
|
2151
|
+
return n3 === void 0 ? r4 : Object.assign(r4, { lazy: n3, lazyArgs: t6 });
|
|
2152
|
+
}
|
|
2153
|
+
|
|
2154
|
+
// ../../node_modules/.pnpm/remeda@2.32.0/node_modules/remeda/dist/purry-DH9cw9sy.js
|
|
2155
|
+
function t(t6, n3, r4) {
|
|
2156
|
+
let i3 = t6.length - n3.length;
|
|
2157
|
+
if (i3 === 0)
|
|
2158
|
+
return t6(...n3);
|
|
2159
|
+
if (i3 === 1)
|
|
2160
|
+
return e(t6, n3, r4);
|
|
2161
|
+
throw Error(`Wrong number of arguments`);
|
|
2162
|
+
}
|
|
2163
|
+
|
|
2164
|
+
// ../../node_modules/.pnpm/remeda@2.32.0/node_modules/remeda/dist/utilityEvaluators-DORpnx39.js
|
|
2165
|
+
var t2 = { done: false, hasNext: false };
|
|
2166
|
+
var r = (e2) => ({ hasNext: true, next: e2, done: false });
|
|
2157
2167
|
|
|
2158
|
-
// ../../node_modules/.pnpm/remeda@2.
|
|
2159
|
-
function
|
|
2160
|
-
let
|
|
2161
|
-
for (;
|
|
2162
|
-
if (
|
|
2163
|
-
let
|
|
2164
|
-
|
|
2168
|
+
// ../../node_modules/.pnpm/remeda@2.32.0/node_modules/remeda/dist/pipe-jLehR9-P.js
|
|
2169
|
+
function t3(e2, ...t6) {
|
|
2170
|
+
let a = e2, o = t6.map((e3) => `lazy` in e3 ? r2(e3) : void 0), s = 0;
|
|
2171
|
+
for (; s < t6.length; ) {
|
|
2172
|
+
if (o[s] === void 0 || !i(a)) {
|
|
2173
|
+
let e4 = t6[s];
|
|
2174
|
+
a = e4(a), s += 1;
|
|
2165
2175
|
continue;
|
|
2166
2176
|
}
|
|
2167
|
-
let
|
|
2168
|
-
for (let
|
|
2169
|
-
let
|
|
2170
|
-
if (
|
|
2177
|
+
let e3 = [];
|
|
2178
|
+
for (let n3 = s; n3 < t6.length; n3++) {
|
|
2179
|
+
let t7 = o[n3];
|
|
2180
|
+
if (t7 === void 0 || (e3.push(t7), t7.isSingle))
|
|
2171
2181
|
break;
|
|
2172
2182
|
}
|
|
2173
|
-
let
|
|
2174
|
-
for (let
|
|
2175
|
-
if (
|
|
2183
|
+
let r4 = [];
|
|
2184
|
+
for (let t7 of a)
|
|
2185
|
+
if (n(t7, r4, e3))
|
|
2176
2186
|
break;
|
|
2177
|
-
let { isSingle:
|
|
2178
|
-
|
|
2187
|
+
let { isSingle: c } = e3.at(-1);
|
|
2188
|
+
a = c ? r4[0] : r4, s += e3.length;
|
|
2179
2189
|
}
|
|
2180
|
-
return
|
|
2190
|
+
return a;
|
|
2181
2191
|
}
|
|
2182
|
-
function
|
|
2183
|
-
if (
|
|
2184
|
-
return
|
|
2185
|
-
let
|
|
2186
|
-
for (let [
|
|
2187
|
-
let { index:
|
|
2188
|
-
if (
|
|
2189
|
-
if (
|
|
2190
|
-
for (let
|
|
2191
|
-
if (
|
|
2192
|
+
function n(t6, r4, i3) {
|
|
2193
|
+
if (i3.length === 0)
|
|
2194
|
+
return r4.push(t6), false;
|
|
2195
|
+
let a = t6, o = t2, s = false;
|
|
2196
|
+
for (let [e2, t7] of i3.entries()) {
|
|
2197
|
+
let { index: c, items: l } = t7;
|
|
2198
|
+
if (l.push(a), o = t7(a, c, l), t7.index += 1, o.hasNext) {
|
|
2199
|
+
if (o.hasMany ?? false) {
|
|
2200
|
+
for (let t8 of o.next)
|
|
2201
|
+
if (n(t8, r4, i3.slice(e2 + 1)))
|
|
2192
2202
|
return true;
|
|
2193
|
-
return
|
|
2203
|
+
return s;
|
|
2194
2204
|
}
|
|
2195
|
-
|
|
2205
|
+
a = o.next;
|
|
2196
2206
|
}
|
|
2197
|
-
if (!
|
|
2207
|
+
if (!o.hasNext)
|
|
2198
2208
|
break;
|
|
2199
|
-
|
|
2209
|
+
o.done && (s = true);
|
|
2200
2210
|
}
|
|
2201
|
-
return
|
|
2211
|
+
return o.hasNext && r4.push(a), s;
|
|
2202
2212
|
}
|
|
2203
|
-
function
|
|
2204
|
-
let { lazy:
|
|
2205
|
-
return Object.assign(
|
|
2213
|
+
function r2(e2) {
|
|
2214
|
+
let { lazy: t6, lazyArgs: n3 } = e2, r4 = t6(...n3);
|
|
2215
|
+
return Object.assign(r4, { isSingle: t6.single ?? false, index: 0, items: [] });
|
|
2206
2216
|
}
|
|
2207
|
-
function
|
|
2208
|
-
return typeof
|
|
2217
|
+
function i(e2) {
|
|
2218
|
+
return typeof e2 == `string` || typeof e2 == `object` && !!e2 && Symbol.iterator in e2;
|
|
2209
2219
|
}
|
|
2210
2220
|
|
|
2211
|
-
// ../../node_modules/.pnpm/remeda@2.
|
|
2212
|
-
function
|
|
2213
|
-
let
|
|
2214
|
-
if (
|
|
2215
|
-
let [
|
|
2216
|
-
return
|
|
2217
|
-
}
|
|
2218
|
-
if (
|
|
2219
|
-
let
|
|
2220
|
-
return Object.assign((
|
|
2221
|
-
}
|
|
2222
|
-
throw
|
|
2221
|
+
// ../../node_modules/.pnpm/remeda@2.32.0/node_modules/remeda/dist/purryFromLazy-3oywCNIb.js
|
|
2222
|
+
function t4(t6, n3) {
|
|
2223
|
+
let r4 = n3.length - t6.length;
|
|
2224
|
+
if (r4 === 1) {
|
|
2225
|
+
let [r5, ...i3] = n3;
|
|
2226
|
+
return t3(r5, { lazy: t6, lazyArgs: i3 });
|
|
2227
|
+
}
|
|
2228
|
+
if (r4 === 0) {
|
|
2229
|
+
let r5 = { lazy: t6, lazyArgs: n3 };
|
|
2230
|
+
return Object.assign((t7) => t3(t7, r5), r5);
|
|
2231
|
+
}
|
|
2232
|
+
throw Error(`Wrong number of arguments`);
|
|
2223
2233
|
}
|
|
2224
2234
|
|
|
2225
|
-
// ../../node_modules/.pnpm/remeda@2.
|
|
2226
|
-
function
|
|
2227
|
-
|
|
2228
|
-
return a2 === void 0 ? t : Object.assign(t, { lazy: a2, lazyArgs: n });
|
|
2235
|
+
// ../../node_modules/.pnpm/remeda@2.32.0/node_modules/remeda/dist/difference-DxYg8_zs.js
|
|
2236
|
+
function r3(...e2) {
|
|
2237
|
+
return t4(i2, e2);
|
|
2229
2238
|
}
|
|
2230
|
-
|
|
2231
|
-
|
|
2232
|
-
|
|
2233
|
-
let
|
|
2234
|
-
|
|
2235
|
-
|
|
2236
|
-
|
|
2237
|
-
|
|
2238
|
-
|
|
2239
|
-
}
|
|
2240
|
-
|
|
2241
|
-
// ../../node_modules/.pnpm/remeda@2.21.3/node_modules/remeda/dist/chunk-ENS7GPLZ.js
|
|
2242
|
-
function a(...r) {
|
|
2243
|
-
return u2(o2, r);
|
|
2244
|
-
}
|
|
2245
|
-
function o2(r, t) {
|
|
2246
|
-
let e = [];
|
|
2247
|
-
for (let n = r; n < t; n++)
|
|
2248
|
-
e.push(n);
|
|
2249
|
-
return e;
|
|
2239
|
+
function i2(n3) {
|
|
2240
|
+
if (n3.length === 0)
|
|
2241
|
+
return r;
|
|
2242
|
+
let r4 = /* @__PURE__ */ new Map();
|
|
2243
|
+
for (let e2 of n3)
|
|
2244
|
+
r4.set(e2, (r4.get(e2) ?? 0) + 1);
|
|
2245
|
+
return (t6) => {
|
|
2246
|
+
let n4 = r4.get(t6);
|
|
2247
|
+
return n4 === void 0 || n4 === 0 ? { done: false, hasNext: true, next: t6 } : (r4.set(t6, n4 - 1), t2);
|
|
2248
|
+
};
|
|
2250
2249
|
}
|
|
2251
2250
|
|
|
2252
|
-
// ../../node_modules/.pnpm/remeda@2.
|
|
2253
|
-
function
|
|
2254
|
-
return
|
|
2251
|
+
// ../../node_modules/.pnpm/remeda@2.32.0/node_modules/remeda/dist/range-amdmPz_6.js
|
|
2252
|
+
function t5(...t6) {
|
|
2253
|
+
return t(n2, t6);
|
|
2255
2254
|
}
|
|
2256
|
-
function
|
|
2257
|
-
|
|
2258
|
-
|
|
2259
|
-
|
|
2260
|
-
|
|
2261
|
-
n.set(r, (n.get(r) ?? 0) + 1);
|
|
2262
|
-
return (r) => {
|
|
2263
|
-
let t = n.get(r);
|
|
2264
|
-
return t === void 0 || t === 0 ? { done: false, hasNext: true, next: r } : (n.set(r, t - 1), s);
|
|
2265
|
-
};
|
|
2255
|
+
function n2(e2, t6) {
|
|
2256
|
+
let n3 = [];
|
|
2257
|
+
for (let r4 = e2; r4 < t6; r4++)
|
|
2258
|
+
n3.push(r4);
|
|
2259
|
+
return n3;
|
|
2266
2260
|
}
|
|
2267
2261
|
|
|
2268
2262
|
// ../../dev/server/src/port.ts
|
|
@@ -2343,7 +2337,7 @@ async function tryAnyPort(options) {
|
|
|
2343
2337
|
...Object.values(portsUsedByThisServerLastTime || {})
|
|
2344
2338
|
];
|
|
2345
2339
|
const maximumSpecificPort = Math.min(Math.max(minimumPort, ...excludedPorts) + 100, MAX_PORT);
|
|
2346
|
-
const ports =
|
|
2340
|
+
const ports = r3(t5(minimumPort, maximumSpecificPort), excludedPorts);
|
|
2347
2341
|
const defaultPort2 = {
|
|
2348
2342
|
port: DEFAULT_SERVER_PORT,
|
|
2349
2343
|
databasePort: DEFAULT_DATABASE_PORT,
|
|
@@ -2638,7 +2632,7 @@ async function getApp(port, dbServer, serverState) {
|
|
|
2638
2632
|
const { debug: debug3 } = serverState;
|
|
2639
2633
|
const [{ Hono }, { accelerateRoute }, { utilityRoute }] = await Promise.all([
|
|
2640
2634
|
import("hono/tiny"),
|
|
2641
|
-
import("./accelerate-
|
|
2635
|
+
import("./accelerate-5VID4BSA.js"),
|
|
2642
2636
|
import("./utility-QJR3G2JJ.js")
|
|
2643
2637
|
]);
|
|
2644
2638
|
const app = new Hono();
|
|
@@ -3475,8 +3469,8 @@ var GeneratedFiles = class _GeneratedFiles {
|
|
|
3475
3469
|
yield entry;
|
|
3476
3470
|
}
|
|
3477
3471
|
}
|
|
3478
|
-
format(
|
|
3479
|
-
return new Formatter(this,
|
|
3472
|
+
format(f) {
|
|
3473
|
+
return new Formatter(this, f).formatToString();
|
|
3480
3474
|
}
|
|
3481
3475
|
};
|
|
3482
3476
|
var Formatter = class _Formatter {
|
|
@@ -3519,8 +3513,8 @@ var FileWriter = class {
|
|
|
3519
3513
|
fs3.writeFileSync(absPath, content, options);
|
|
3520
3514
|
this.#files.add(absPath);
|
|
3521
3515
|
}
|
|
3522
|
-
format(
|
|
3523
|
-
return this.#files.format(
|
|
3516
|
+
format(f) {
|
|
3517
|
+
return this.#files.format(f);
|
|
3524
3518
|
}
|
|
3525
3519
|
};
|
|
3526
3520
|
|
|
@@ -3929,9 +3923,9 @@ var Init = class _Init {
|
|
|
3929
3923
|
})
|
|
3930
3924
|
})).json()
|
|
3931
3925
|
));
|
|
3932
|
-
} catch (
|
|
3926
|
+
} catch (e2) {
|
|
3933
3927
|
spinner2.fail();
|
|
3934
|
-
throw
|
|
3928
|
+
throw e2;
|
|
3935
3929
|
}
|
|
3936
3930
|
spinner2.succeed("Schema is ready");
|
|
3937
3931
|
}
|
|
@@ -4060,15 +4054,15 @@ var Init = class _Init {
|
|
|
4060
4054
|
const gitignorePath = path5.join(outputDir, ".gitignore");
|
|
4061
4055
|
try {
|
|
4062
4056
|
writer.write(gitignorePath, defaultGitIgnore(), { flag: "wx" });
|
|
4063
|
-
} catch (
|
|
4064
|
-
if (
|
|
4057
|
+
} catch (e2) {
|
|
4058
|
+
if (e2.code === "EEXIST") {
|
|
4065
4059
|
warnings.push(
|
|
4066
4060
|
`${yellow(
|
|
4067
4061
|
"warn"
|
|
4068
4062
|
)} You already have a ${bold2(".gitignore file.")} Don't forget to add ${bold2(".env")} in it to not commit any private information.`
|
|
4069
4063
|
);
|
|
4070
4064
|
} else {
|
|
4071
|
-
console.error("Failed to write .gitignore file, reason: ",
|
|
4065
|
+
console.error("Failed to write .gitignore file, reason: ", e2);
|
|
4072
4066
|
}
|
|
4073
4067
|
}
|
|
4074
4068
|
const clientPathRelativeToOutputDir = path5.relative(outputDir, path5.resolve(prismaFolder, clientOutput));
|
|
@@ -4076,8 +4070,8 @@ var Init = class _Init {
|
|
|
4076
4070
|
fs4.appendFileSync(gitignorePath, `
|
|
4077
4071
|
/${clientPathRelativeToOutputDir.replaceAll(path5.sep, "/")}
|
|
4078
4072
|
`);
|
|
4079
|
-
} catch (
|
|
4080
|
-
console.error("Failed to append client path to .gitignore file, reason: ",
|
|
4073
|
+
} catch (e2) {
|
|
4074
|
+
console.error("Failed to append client path to .gitignore file, reason: ", e2);
|
|
4081
4075
|
}
|
|
4082
4076
|
const connectExistingDatabaseSteps = ` 1. Configure your DATABASE_URL in ${green2("prisma.config.ts")}
|
|
4083
4077
|
2. Run ${green2(internals.getCommandWithExecutor("prisma db pull"))} to introspect your database.`;
|