From 61302ab7a09cc4c298c903d725e35355eb069497 Mon Sep 17 00:00:00 2001 From: Nate Moore Date: Fri, 16 Dec 2022 15:48:03 -0500 Subject: [PATCH] fix(create-astro): skip Houston on windows until prompts are fixed (#5616) Co-authored-by: Nate Moore --- .changeset/violet-parents-mix.md | 5 +++++ packages/create-astro/package.json | 2 +- packages/create-astro/src/index.ts | 3 +++ pnpm-lock.yaml | 8 ++++---- 4 files changed, 13 insertions(+), 5 deletions(-) create mode 100644 .changeset/violet-parents-mix.md diff --git a/.changeset/violet-parents-mix.md b/.changeset/violet-parents-mix.md new file mode 100644 index 000000000..886d1a20d --- /dev/null +++ b/.changeset/violet-parents-mix.md @@ -0,0 +1,5 @@ +--- +'create-astro': patch +--- + +Skip Houston on Windows until we can debug the prompt issue diff --git a/packages/create-astro/package.json b/packages/create-astro/package.json index 6a6fa0664..a129f0863 100644 --- a/packages/create-astro/package.json +++ b/packages/create-astro/package.json @@ -29,7 +29,7 @@ "tsconfigs" ], "dependencies": { - "@astrojs/cli-kit": "^0.1.4", + "@astrojs/cli-kit": "^0.1.6", "chalk": "^5.0.1", "comment-json": "^4.2.3", "execa": "^6.1.0", diff --git a/packages/create-astro/src/index.ts b/packages/create-astro/src/index.ts index 9fe81f987..1e934fc9b 100644 --- a/packages/create-astro/src/index.ts +++ b/packages/create-astro/src/index.ts @@ -7,6 +7,7 @@ import fs from 'fs'; import { downloadTemplate } from 'giget'; import { bold, dim, green, reset, yellow } from 'kleur/colors'; import ora from 'ora'; +import { platform } from 'os'; import path from 'path'; import prompts from 'prompts'; import detectPackageManager from 'which-pm-runs'; @@ -30,6 +31,8 @@ import { TEMPLATES } from './templates.js'; // fixes the issue so that create-astro now works on all npm version. const cleanArgv = process.argv.filter((arg) => arg !== '--'); const args = yargs(cleanArgv, { boolean: ['fancy'] }); +// Always skip Houston on Windows (for now) +if (platform() === 'win32') args.skipHouston = true; prompts.override(args); // Enable full unicode support if the `--fancy` flag is passed diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 8044455da..d72416a7c 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -2583,7 +2583,7 @@ importers: packages/create-astro: specifiers: - '@astrojs/cli-kit': ^0.1.4 + '@astrojs/cli-kit': ^0.1.6 '@types/chai': ^4.3.1 '@types/degit': ^2.8.3 '@types/mocha': ^9.1.1 @@ -2605,7 +2605,7 @@ importers: which-pm-runs: ^1.1.0 yargs-parser: ^21.0.1 dependencies: - '@astrojs/cli-kit': 0.1.5 + '@astrojs/cli-kit': 0.1.6 chalk: 5.1.2 comment-json: 4.2.3 execa: 6.1.0 @@ -3960,8 +3960,8 @@ packages: lite-youtube-embed: 0.2.0 dev: false - /@astrojs/cli-kit/0.1.5: - resolution: {integrity: sha512-i0eYbGvg6pTz2A5bsMd5QnBTqA7WusXu4YUYzV2x6uPKkiO62TZK1aPK/llGaKaYC3riCVP/qahOK5v/lsrkdA==} + /@astrojs/cli-kit/0.1.6: + resolution: {integrity: sha512-hC0Z7kh4T5QdtfPJVyZ6qmNCqWFYg67zS64AxPm9Y8QVYfeXOdXfL3PaNPGbNtGmczmYJ7cBn/ImgXd/RTTc5g==} dependencies: chalk: 5.1.2 log-update: 5.0.1