Skip to content

Add Windows-native which command#59

Open
caomengxuan666 wants to merge 1 commit into
microsoft:mainfrom
caomengxuan666:winuxcmd/which
Open

Add Windows-native which command#59
caomengxuan666 wants to merge 1 commit into
microsoft:mainfrom
caomengxuan666:winuxcmd/which

Conversation

@caomengxuan666

Copy link
Copy Markdown
Contributor

Adds a small Windows-native which implementation.

It searches PATH, respects PATHEXT on Windows, supports -a/--all, and returns a non-zero exit code when any requested command is not found.

This came out of the scope discussion in #56: which is common on Unix/macOS and fills a small PowerShell gap without needing a POSIX layer.

Validation:

  • cargo test -p uu_which
  • cargo check
  • target\debug\coreutils.exe which powershell

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.

1 participant