fix(nushell): use caret for invoking cmd in completion script#638
Conversation
Greptile SummaryThis PR fixes an issue in the generated nushell completion script where external commands were being invoked without the
Confidence Score: 5/5Safe to merge — the change is a minimal, targeted fix that correctly adds the nushell external-command sigil at every affected call site. All three invocation sites in the generator and all three corresponding snapshot files are consistently updated. The fix aligns with documented nushell behavior and the snapshots confirm the tests will pass. No files require special attention. Important Files Changed
Reviews (3): Last reviewed commit: "fix(nushell): use caret for invoking cmd..." | Re-trigger Greptile |
There was a problem hiding this comment.
Code Review
This pull request updates the Nushell completion logic in lib/src/complete/nu.rs by prefixing external command calls with a caret (^) to ensure the external binary is executed directly, bypassing any potential Nushell aliases or built-ins. I have no feedback to provide as there were no review comments to evaluate.
18b683c to
40e6097
Compare
40e6097 to
04c8673
Compare
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #638 +/- ##
=======================================
Coverage 75.34% 75.34%
=======================================
Files 49 49
Lines 7389 7389
Branches 7389 7389
=======================================
Hits 5567 5567
Misses 1217 1217
Partials 605 605 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
This PR modifies the nushell completion script to use caret for invoking commands. This fixes the following issue.
Issue
The generated nushell completion script does not use caret for invoking external commands which causes the shell to interpret
{usage_cmd}as a nushell function, producing an error.Steps to reproduce
~/.config/nushell/config.nu: