Skip to content

micro-fix(quickstart.ps1): correct npm invocation in powershell script#6816

Merged
Hundao merged 1 commit intoaden-hive:mainfrom
Leayxz:micro-fix/wrong_call_operator
Apr 6, 2026
Merged

micro-fix(quickstart.ps1): correct npm invocation in powershell script#6816
Hundao merged 1 commit intoaden-hive:mainfrom
Leayxz:micro-fix/wrong_call_operator

Conversation

@Leayxz
Copy link
Copy Markdown
Contributor

@Leayxz Leayxz commented Mar 26, 2026

Description

  • powerShell supports direct command invocation without requiring the call operator "&"
  • the script used the call operator "&" to invoke npm install and npm run build
  • which caused incorrect command parsing in PowerShell when combined with output redirection "2>&1"
  • This resulted in unexpected errors such as "Unknown command: pm", even though the commands worked correctly when executed manually

Type of Change

  • Bug fix (non-breaking change that fixes an issue)
  • New feature (non-breaking change that adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation update
  • Refactoring (no functional changes)

Related Issues

  • no issue or PRs related

Changes Made

  • removed the unnecessary use of the call operator "&" and invoked npm commands directly
  • npm commands now execute correctly within the script, aligning with standard PowerShell behavior and eliminating the parsing issue

Testing

  • Unit tests pass (cd core && pytest tests/)
  • Lint passes (cd core && ruff check .)
  • Manual testing performed

Checklist

  • My code follows the project's style guidelines
  • I have performed a self-review of my code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes

Summary by CodeRabbit

  • Chores
    • Updated the project setup script to change how install and build commands are invoked for more reliable setup runs.
    • Preserved existing output capture, success/failure detection, and logging so user-facing behavior is unchanged.
    • No changes to public interfaces or exported functionality.

@Leayxz Leayxz changed the title micro-fix(quickstart): correct npm invocation in powershell script micro-fix(quickstart.ps1): correct npm invocation in powershell script Mar 26, 2026
@Leayxz Leayxz force-pushed the micro-fix/wrong_call_operator branch from 6ca3049 to b1d6589 Compare March 28, 2026 23:20
@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Mar 28, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 6932323f-49bc-429b-a863-323d20a5a216

📥 Commits

Reviewing files that changed from the base of the PR and between b102c94 and b07d1db.

📒 Files selected for processing (1)
  • quickstart.ps1

📝 Walkthrough

Walkthrough

Updated npm command invocations in quickstart.ps1 by removing the PowerShell call operator (&) to run commands directly. The npm install --no-fund --no-audit and npm run build commands are executed without the call operator; exit code checks and error handling via $LASTEXITCODE remain unchanged.

Changes

Cohort / File(s) Summary
PowerShell Build Script
quickstart.ps1
Removed PowerShell call operator (&) from npm command invocations; changed & npm install --no-fund --no-audit 2>&1 and & npm run build 2>&1 to direct executions while preserving output capture (2>&1) and $LASTEXITCODE-based error handling.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

Poem

A rabbit hops through scripts so fine, 🐰
The ampersand slips, the commands align.
Build still hums and logs still show,
Exit codes watch the ebb and flow.
Small change, same path—onward we go.

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and specifically describes the main change: fixing npm invocation in a PowerShell script by removing the call operator.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Comment @coderabbitai help to get the list of available commands and usage tips.

@Leayxz
Copy link
Copy Markdown
Contributor Author

Leayxz commented Apr 1, 2026

@bryanadenhq

@Leayxz Leayxz force-pushed the micro-fix/wrong_call_operator branch from b1d6589 to b102c94 Compare April 2, 2026 14:25
- powerShell supports direct command invocation without requiring the call operator "&"
- the script used the call operator "&" to invoke `npm install` and `npm run build`
- which caused incorrect command parsing in PowerShell when combined with output redirection "2>&1"
- This resulted in unexpected errors such as "Unknown command: pm", even though the commands worked correctly when executed manually

- removed the unnecessary use of the call operator "&" and invoked npm commands directly
- npm commands now execute correctly within the script, aligning with standard PowerShell behavior and eliminating the parsing issue
@Leayxz Leayxz force-pushed the micro-fix/wrong_call_operator branch from b102c94 to b07d1db Compare April 5, 2026 14:58
@Leayxz
Copy link
Copy Markdown
Contributor Author

Leayxz commented Apr 5, 2026

@Hundao

@Hundao Hundao merged commit 4b79558 into aden-hive:main Apr 6, 2026
9 checks passed
@Leayxz Leayxz deleted the micro-fix/wrong_call_operator branch April 6, 2026 17:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants