Skip to content
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions packages/nuxi/src/commands/init.ts
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@
bun: undefined,
deno: undefined,
aube: undefined,
nub: undefined,

Check failure on line 45 in packages/nuxi/src/commands/init.ts

View workflow job for this annotation

GitHub Actions / ci (ubuntu-latest)

Object literal may only specify known properties, and 'nub' does not exist in type 'Record<PackageManagerName, undefined>'.

Check failure on line 45 in packages/nuxi/src/commands/init.ts

View workflow job for this annotation

GitHub Actions / ci (macos-latest)

Object literal may only specify known properties, and 'nub' does not exist in type 'Record<PackageManagerName, undefined>'.

Check failure on line 45 in packages/nuxi/src/commands/init.ts

View workflow job for this annotation

GitHub Actions / ci (windows-latest)

Object literal may only specify known properties, and 'nub' does not exist in type 'Record<PackageManagerName, undefined>'.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎯 Functional Correctness | 🟠 Major | ⚡ Quick win

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Inspect nypm's installed type declarations for the exact package manager literal
fd -HI 'nypm' -t d node_modules | head -5
fd -HI '.d.ts' node_modules/nypm 2>/dev/null | xargs -I{} grep -n "PackageManagerName\|nub\|aube" {} 2>/dev/null

Repository: nuxt/cli

Length of output: 226


🏁 Script executed:

#!/bin/bash
set -euo pipefail

# Locate nypm declaration files and inspect the relevant type definitions.
NPM_ROOT="node_modules/.pnpm/nypm@0.6.7/node_modules/nypm"

echo "== files =="
fd -H -t f . "$NPM_ROOT" | sed -n '1,120p'

echo
echo "== package-manager references =="
rg -n "PackageManagerName|nub|aube|PackageManager" "$NPM_ROOT" || true

echo
echo "== likely type declaration slices =="
for f in $(fd -H -t f '\.d\.ts$' "$NPM_ROOT"); do
  if rg -n "PackageManagerName|nub|aube" "$f" >/dev/null; then
    echo "--- $f ---"
    sed -n '1,220p' "$f"
  fi
done

Repository: nuxt/cli

Length of output: 827


🏁 Script executed:

#!/bin/bash
set -euo pipefail

PKG="node_modules/.pnpm/nypm@0.6.7/node_modules/nypm"

echo "== package.json =="
cat "$PKG/package.json"

echo
echo "== nearby nypm files =="
fd -H -t f 'nypm' node_modules/.pnpm | sed -n '1,200p'

echo
echo "== aube/nub references in the pnpm store =="
rg -n "PackageManagerName|nub|aube" node_modules/.pnpm/nypm@0.6.7 node_modules/.pnpm -g '!**/README.md' -g '!**/LICENSE' || true

Repository: nuxt/cli

Length of output: 1654


🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "== target file =="
cat -n packages/nuxi/src/commands/init.ts | sed -n '1,140p'

echo
echo "== package manager name definitions/usages =="
rg -n "type PackageManagerName|PackageManagerName|packageManagerOptions|nub: undefined|aube: undefined|packageManager" packages -g '!**/dist/**' || true

echo
echo "== nypm references =="
rg -n "\bnypm\b|\baube\b|\bnub\b" packages -g '!**/dist/**' || true

Repository: nuxt/cli

Length of output: 17743


Use aube here, not nub
nypm 0.6.7 lists the new package manager as aube; packageManagerOptions is derived from these keys, so nub will make --packageManager=nub invalid and can break the Record<PackageManagerName, undefined> check.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@packages/nuxi/src/commands/init.ts` at line 45, The package manager option
key is still using the old name, which will make init generate an invalid
package manager value. Update the `packageManagerOptions` entry in `init.ts`
from `nub` to `aube`, and ensure the `Record<PackageManagerName, undefined>`
keys and any related `PackageManagerName` usage stay aligned with the new
package manager name.

}

// this is for type safety to prompt updating code in nuxi when nypm adds a new package manager
Expand Down
Loading