create-astro 4.5.0 → 4.5.2-beta.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/index.js CHANGED
@@ -384,7 +384,7 @@ function printHelp({
384
384
  if (headline) {
385
385
  message.push(
386
386
  linebreak(),
387
- `${title(commandName)} ${color.green(`v${"4.5.0"}`)} ${headline}`
387
+ `${title(commandName)} ${color.green(`v${"4.5.2-beta.0"}`)} ${headline}`
388
388
  );
389
389
  }
390
390
  if (usage) {
@@ -513,17 +513,16 @@ async function dependencies(ctx) {
513
513
  await spinner({
514
514
  start: `Installing dependencies with ${ctx.packageManager}...`,
515
515
  end: "Dependencies installed",
516
- while: () => {
517
- return install({ packageManager: ctx.packageManager, cwd: ctx.cwd }).catch((e) => {
518
- error("error", e);
519
- error(
520
- "error",
521
- `Dependencies failed to install, please run ${color2.bold(
522
- ctx.packageManager + " install"
523
- )} to install them manually after setup.`
524
- );
525
- });
526
- }
516
+ onError: (e) => {
517
+ error("error", e);
518
+ error(
519
+ "error",
520
+ `Dependencies failed to install, please run ${color2.bold(
521
+ ctx.packageManager + " install"
522
+ )} to install them manually after setup.`
523
+ );
524
+ },
525
+ while: () => install({ packageManager: ctx.packageManager, cwd: ctx.cwd })
527
526
  });
528
527
  } else {
529
528
  await info(
@@ -1155,7 +1154,7 @@ var exit = () => process.exit(0);
1155
1154
  process.on("SIGINT", exit);
1156
1155
  process.on("SIGTERM", exit);
1157
1156
  async function main() {
1158
- console.clear();
1157
+ console.log("");
1159
1158
  const cleanArgv = process.argv.slice(2).filter((arg2) => arg2 !== "--");
1160
1159
  const ctx = await getContext(cleanArgv);
1161
1160
  if (ctx.help) {
@@ -1,5 +1,3 @@
1
- /** @internal Used to mock `process.stdout.write` for testing purposes */
2
- export declare function setStdout(writable: typeof process.stdout): void;
3
1
  export declare function say(messages: string | string[], { clear, hat }?: {
4
2
  clear?: boolean | undefined;
5
3
  hat?: string | undefined;
@@ -7,6 +5,7 @@ export declare function say(messages: string | string[], { clear, hat }?: {
7
5
  export declare function spinner(args: {
8
6
  start: string;
9
7
  end: string;
8
+ onError?: (error: any) => void;
10
9
  while: (...args: any) => Promise<any>;
11
10
  }): Promise<void>;
12
11
  export declare const title: (text: string) => string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "create-astro",
3
- "version": "4.5.0",
3
+ "version": "4.5.2-beta.0",
4
4
  "type": "module",
5
5
  "author": "withastro",
6
6
  "license": "MIT",
@@ -25,8 +25,8 @@
25
25
  "//a": "MOST PACKAGES SHOULD GO IN DEV_DEPENDENCIES! THEY WILL BE BUNDLED.",
26
26
  "//b": "DEPENDENCIES IS FOR UNBUNDLED PACKAGES",
27
27
  "dependencies": {
28
- "@astrojs/cli-kit": "^0.3.0",
29
- "giget": "1.1.2"
28
+ "@astrojs/cli-kit": "^0.3.1",
29
+ "giget": "1.1.3"
30
30
  },
31
31
  "devDependencies": {
32
32
  "arg": "^5.0.2",