Skip to content

Commit 6cdc424

Browse files
authored
fix(build-system-tests): pass --no-gitInit & --packageManager to nuxi init for CI (#7029)
* fix(build-system-tests): pass --no-gitInit to nuxi init for CI nuxi >=3.36 now requires an explicit --gitInit/--no-gitInit argument when run in a non-interactive terminal. The hourly Build System Test Canary (vue/nuxt latest) job pins nuxi@latest, so the new CLI broke 'nuxi init' with: Non-interactive terminal detected. Missing required argument: --gitInit Process completed with exit code 2 The mega-app is throwaway and needs no git repo, so pass --no-gitInit. Fixes the Github Build System Test Failure alarm (V2257625415). * fix(build-system-tests): also pass --packageManager=npm to nuxi init nuxi >=3.36 requires BOTH --gitInit and --packageManager as explicit flags in a non-interactive terminal. --no-gitInit alone advances to a second failure: 'Missing required argument: --packageManager'. Verified locally that 'nuxi init -t v4 --no-gitInit --packageManager=npm' exits 0 and scaffolds the project. build-system-tests is npm-based throughout.
1 parent 091c4cf commit 6cdc424

1 file changed

Lines changed: 7 additions & 2 deletions

File tree

build-system-tests/scripts/mega-app-create-app.sh

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -91,8 +91,13 @@ if [[ "$FRAMEWORK" == 'vue' ]]; then
9191
echo "vue create --preset ../templates/components/vue/preset-${FRAMEWORK_VERSION}.json $MEGA_APP_NAME"
9292
echo 'Y' | vue create --preset ../templates/components/vue/preset-${FRAMEWORK_VERSION}.json $MEGA_APP_NAME
9393
elif [ "$BUILD_TOOL" == 'nuxt' ]; then
94-
echo "npx nuxi@latest init $MEGA_APP_NAME -t v4"
95-
npx nuxi@latest init $MEGA_APP_NAME -t v4
94+
# nuxi >=3.36 no longer defaults the interactive prompts in a non-interactive
95+
# terminal (CI); it requires them as explicit flags or fails with exit code 2.
96+
# Two prompts apply here: --gitInit (the mega-app is throwaway, no git repo
97+
# needed -> --no-gitInit) and --packageManager (the rest of build-system-tests
98+
# is npm-based -> npm).
99+
echo "npx nuxi@latest init $MEGA_APP_NAME -t v4 --no-gitInit --packageManager=npm"
100+
npx nuxi@latest init $MEGA_APP_NAME -t v4 --no-gitInit --packageManager=npm
96101
fi
97102
fi
98103

0 commit comments

Comments
 (0)