mafredri / zsh-async

Because your terminal should be able to perform tasks asynchronously without external tools!
MIT License
756 stars 37 forks source link

Plans to make it work on Windows? #26

Open mike-code opened 6 years ago

mike-code commented 6 years ago

as topic says

mafredri commented 6 years ago

There are no plans at the moment. But I know async has been used on Windows (with varying degrees of success), and it should (maybe) work if zsh works. It would be great to know what you tried and what problems you encountered.

agkozak commented 6 years ago

zsh-async works perfectly, as far as I know, in WSL. It doesn't work in Cygwin or MSys2 because zpty doesn't work.

My prompt agkozak-zsh-theme uses zsh-async with a fallback to a TRAPUSR1()-based method when that won't work. It works in all the Windows contexts that I've tried it with.

mafredri commented 6 years ago

@agkozak thanks for your input! I've heard reports of zsh-async working (somewhat?) in Babun, but I can't really confirm this, and it might have been unreliable.

We might be able to fall-back to the method suggested in #24 (or implement it as an alternative async backend) on Windows. If it works, it should be more reliable than using kill-signals.

borekb commented 6 years ago

It seems that more and more prompts are starting to implement asynchronicity via zsh-async which makes us, stuck with MSYS2, suffer quite a bit :) Would be awesome if some fallback was implemented.

borekb commented 6 years ago

Just occurred to me that even synchronous fallback (if technically possible) would be better than (zpty):zpty:12: can't open pseudo terminal: bad file descriptor, IMO. Sounds like a terrible idea though.