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

Rokit is unusable on Windows because current_exe_name strips EXE_EXTENSION instead of EXE_SUFFIX #9

Closed
kennethloeffler opened this issue Apr 23, 2024 · 0 comments · Fixed by #10
Labels
bug Something isn't working

Comments

@kennethloeffler
Copy link
Member

In Runner::should_run, the CARGO_BIN_NAME environment variable is compared to Runner.exe_name:
https://github.com/filiptibell/rokit/blob/dfdfc12919c3b56fcb4aecc309b92090463f25d7/src/runner/mod.rs#L27-L29

Runner.exe_name is populated using current_exe_name:
https://github.com/filiptibell/rokit/blob/dfdfc12919c3b56fcb4aecc309b92090463f25d7/lib/system/current.rs#L46-L72

EXE_EXTENSION does not include the ., so when this function strips it, we end up with a string like rokit. or rojo..

To fix this, current_exe_name should strip EXE_SUFFIX instead of EXE_EXTENSION.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant