-
Notifications
You must be signed in to change notification settings - Fork 49
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
open::with() fails due to app not found #80
Comments
Byron
added a commit
that referenced
this issue
Jun 21, 2023
…in the program to open with. (#80) This is helpful when testing new features around the `with()` function.
You seem to have found an "incantation" that works for you on Windows and I'd hope this could also work here without breaking others - something I'd be most anxious about. However, it's definitely worth a try, it's just an innocent Please feel free to open a PR to give it a try. |
igdswzcd
pushed a commit
to igdswzcd/open-rs
that referenced
this issue
Jun 25, 2023
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I want to open .avif images by Google Chrome.
Since it doesn't have a default viewer, and I don't want to tell users how to set default opener, So I use
open::with()
by passing "chrome" as the second param.It fails whether I pass "Google Chrome" or "chrome", I looked into source code and found that
open::with()
runs shell like this:I never set chrome's path as an env path, so it surely can't execute by cmd.
However, the
start
cmd inopen::that()
works. I tried such cmd below and it worked.And I modified code in cargo and it also worked in my app. Other apps in this case: msedge, wordpad, WINWORD, etc.
So I wonder could
open::with()
also usestart
to call specific app since we don't usually set app's path as env path in Windows? Or should there be another function usestart
command and specific app at same time?The text was updated successfully, but these errors were encountered: