Closed mathieubodin closed 12 years ago
looks like the desktop
module has an issue with some linux distros.
i have to dig into this. or if you want to contribute, you may start here : http://bugs.python.org/issue1301512
i merged a PR about xdg-open yesterday. can you please update and tell me if its ok ?
Thanks a lot ! Now, it open in browser perfectly, and open the html in sublime text. Works great !
Sorry for the delay...
This still fails with ArchLinux. I get this with st2 :
Traceback (most recent call last):
File "./sublime_plugin.py", line 356, in run_
File "./MarkdownPreview.py", line 168, in run
File "./desktop/__init__.py", line 286, in open
OSError: Desktop 'X11' not supported (neither DESKTOP_LAUNCH nor os.startfile could be used)
I used Package Manager for install (may be the fix is only on the GH repos and not available in PM ?)
xdg-open at the command line works fine.
Thanks.
Yes, this issue needs to be reopened, as it seems to fail on Linux unless you are running any of the commonly used desktop environments (KDE, Gnome, MATE, XFCE). I "fixed" this behavior locally by adding this into def open
in desktop/__init__.py
:
def open(url, desktop=None, wait=0):
...
elif desktop_in_use == "X11":
cmd = ["xdg-open", url]
...
Not sure how valid this fix is, but at least it works as long as you can run xdg-open.
just added this fallback, please confirm, thanks @eddie-dunn
Yes, it works! :)
Hi, I'm facing an issue with this plugin on a LinuxMint distribution (v13). Can't get it to launch the preview. In the console, i've got :
It might be a configuration problem but which one ?
I first add a comment on https://github.com/revolunet/sublimetext-markdown-preview/issues/2 and figure out later that it was closed so there aren't any chance to get it known...