fix(installer): nix-PATH hint, completions error surfacing, dotnet-sdk/landing banners#19
Conversation
…k/landing banners User feedback from a live install surfaced three friction points: 1. **\`nix: command not found\` in new terminals after install.** Determinate wires the system profile, but the curl|sh parent process can't mutate the caller's env. When the "Get started" footer told the user to \`cd ... && nix develop\` in the SAME terminal that launched curl|sh, they hit the missing-PATH error because only our script's subshell had nix sourced. Track whether we installed Nix this run (\$NIX_JUST_INSTALLED / in PS \$script:NixJustInstalled) and emit a prominent note before "Get started" telling the user to either open a new terminal or source the daemon profile script explicitly. Includes a fish-specific hint. 2. **Bash completions failed silently** with \`Failed to generate bash completions — skip\` and no reason. The redirect was \`2>/dev/null\`. Now we capture stderr to a tempfile and echo the first line into the warning when generation fails; also special-case empty-output to tell the user the binary likely predates the \`completions\` subcommand (resq-cli-v0.2.7+ has it). PowerShell variant already captured \$_. 3. **\`print_repo_info\` had no \`dotnet-sdk\` or \`landing\` case.** Users of those repos got no "What's included" banner. Added both (dotnet-sdk: .NET 9 SDK + Protobuf; landing: Bun + Next.js 15 + Tailwind). PowerShell Show-RepoInfo mirrored.
|
Caution Review failedPull request was closed or merged during review 📝 WalkthroughWalkthroughInstallation scripts for both PowerShell and shell environments have been enhanced with improved Nix installation tracking, user-facing PATH notifications, robust error handling for completion generation, and expanded repository information display. Changes
Estimated Code Review Effort🎯 3 (Moderate) | ⏱️ ~20 minutes Poem
🚥 Pre-merge checks | ✅ 2 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Code Review
This pull request updates the installation scripts for both PowerShell and Shell to track whether Nix was installed during the current session, providing a notification to the user if a shell restart or manual profile sourcing is needed. Additionally, it adds project-specific information for .NET SDK and landing repositories. In install.sh, the resq completion generation now captures stderr to provide more descriptive error messages. Review feedback suggests replacing hardcoded temporary file paths in install.sh with mktemp to improve reliability and security.
Applies gemini's review comments on PR #19 (lines 472 and 479). Swap /tmp/resq-compl-err.$$ for mktemp so TMPDIR is honoured and we can't collide with a stale file from a different user on a shared host. Same variable threads through both the success and failure branches for cleanup and stderr-read.
|
Resolved gemini's two review points (both about the same fix):
Rebased onto the main-merge commit before pushing so the PR stays a clean fast-forward. |
Context
Live install feedback exposed three friction points the installer should soften:
Changes
Test plan
Follow-up
Cut `resq-cli-v0.2.7` (merges Stage 1 + 3 into a release) so fresh installs get the `completions` subcommand and tab-completion lights up end-to-end.
🤖 Generated with Claude Code
Summary by CodeRabbit
New Features
Bug Fixes