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

Request: more flexible bin detection #48

Open
AndydeCleyre opened this issue Jan 26, 2020 · 2 comments · May be fixed by #49
Open

Request: more flexible bin detection #48

AndydeCleyre opened this issue Jan 26, 2020 · 2 comments · May be fixed by #49

Comments

@AndydeCleyre
Copy link

AndydeCleyre commented Jan 26, 2020

Detecting presence of a browser shouldn't depend on hard-coded absolute paths, and should handle a little variation in bin name (e.g. "chromium-browser" vs "chromium").

I'm going to submit a PR that attempts to improve this with the help of an extra python dep (plumbum). I understand if it's desirable to implement this without an extra dep, but at least it will serve as an example.

@rhein
Copy link
Contributor

rhein commented Jan 26, 2020

how about solving this with subprocess module (should be more widely installed already I'd say). I have not submitted a PR yet, but maybe you can take a look at my fork at https://github.com/rhein/ice - it also contains some other fixes I found useful for myself.

@AndydeCleyre
Copy link
Author

Go for it, if you like. The PR I submitted should work, too.

Note that if adopted, plumbum could also offer neater replacements for the current uses of os.system, os.path, os.getenv, os.listdir, etc.

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 a pull request may close this issue.

2 participants