Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feature: Use POSIX compliant command -v instead of which #498

Merged
merged 1 commit into from
May 8, 2024

Conversation

KevinAtSesam
Copy link
Contributor

This removes the which package dependency, allowing Linux containers to run with this additional package. See #425 where I previously discussed this.

Example:

[kevin@fedora ~]$ which java
~/.sdkman/candidates/java/current/bin/java
[kevin@fedora ~]$ command -v java
/home/kevin/.sdkman/candidates/java/current/bin/java

[kevin@fedora ~]$ which scalac
~/.sdkman/candidates/scala/current/bin/scalac
[kevin@fedora ~]$ command -v scalac
/home/kevin/.sdkman/candidates/scala/current/bin/scalac

[kevin@fedora ~]$ which readlink
/usr/bin/readlink
[kevin@fedora ~]$ command -v readlink
/usr/bin/readlink
[kevin@fedora ~]$ 

Do note that POSIX dictates hard references, no ~/ support.

This removes the `which` package dependency, allowing Linux containers to run with this additional package.
@xerial xerial merged commit 9cb1a51 into xerial:main May 8, 2024
3 checks passed
@xerial xerial changed the title Use POSIX compliant command -v feature: Use POSIX compliant command -v instead of which May 8, 2024
@xerial xerial added the feature label May 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants