-
Notifications
You must be signed in to change notification settings - Fork 64
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
Set up Cygwin builds #186
Comments
Great testing! It's especially useful to know that it works with file redirection and not when printed directly to the terminal. We're using WriteConsoleA() on Windows in order to make it work in PowerShell etc. - and it behaves differently when redirected to a file. We want to use the native runtime, so building with Cygwin is not an option. But we may be able to find a different workaround. |
From my understanding of the That is why you might need cygwin tools at every point to display sixel on Windows. This includes the terminal and the shell. For example, I used Wezterm + A few notes for completion:
|
It's one of the many issues waiting upon microsoft/terminal#1173. There's nothing chafa can do about it than have a cygwin build. I'll suggest it should be separate from the native windows build, not replace it... i.e treating cygwin as a separate platform. As for wezterm... unfortunately, I don't think it has cywgin support. So, the only way graphics protocols can work is probably via WSL. |
Just wondering, what is the native chafa build used for on Windows, or, what is the drawback of having the defacto Windows build be built by cygwin? I think Wezterm and mintty (Git Bash) are the two main terminals that can display terminal graphics on Windows. |
Interoperability issues, basically. It cuts both ways. In effect, I think @AnonymouX47 is correct. We should be treating Cygwin as an additional platform. This is doable, but every binary distribution I have to do myself adds to release overhead (with the result that I make fewer releases). So I'd be greatly appreciative if someone offered to maintain Cygwin builds. What's the situation with MSYS2 like? I see they have a fork of Cygwin but also ship mingw-w64 packages, including Chafa. Does their Chafa work on their mintty? I'm also curious if Chafa behaves correctly when wrapped in winpty. |
True and understandable. I think a title change and a "help wanted" (or so) lablel would be good. |
chafa -f sixel
and chafa -f iterm
do not work in mintty
iterm image is "empty", just like in the native windows build: My tests were run using the mintty terminal + shell that came with Cygwin. Without gifs somewhat work. I was able to compile chafa with Cygwin straightforwardly. I will document my steps here for someone else to reproduce.
|
@hpjansson, it might be easy to set up msys builds. https://www.msys2.org/dev/new-package/ I am not familiar with creating packages for Arch. Whoever made the chafa Arch package could look at it if it is straightforward. |
I've tagged this with "help wanted" - but with the xz débâcle fresh in mind, I should point out that I won't host binaries built by anyone other than myself on the official site. I might make an exception for someone who's built trust over time, but I'd want to meet personally to verify their identity and exchange keys. In the meantime, Chafa is free software, so anyone can build binaries and host them on their own site - but I can't be responsible for them. Hope that makes sense! |
100% in support! |
This is the image:
I am using the mintty terminal on Windows. I am using bash, which comes with Git for Windows. So, the
cat
program is from there, which is different than powershell'scat
.scoop install git
will install Git for Windows with a terminal called "Git Bash". This is the mintty terminal I am using. See https://mintty.github.io/.chafa -f sixel image.png
produces no output:This is the sixel text file produced by
chafa -f sixel image.png > image.six.txt
:image.six.txt
cat
-ing this text file displays this image, however:chafa -f iterm image.png
produces a large blank screen:This is the iterm text file produced by
chafa -f sixel image.png > image.iterm.txt
:image.iterm.txt
cat
-ing this text file also works.The
./showimg
script in the mintty utils work as expected and display the image correctly with iterm.https://github.com/mintty/utils
According to this, mintty/mintty#1252 (comment) and the other comments in that issue, it seems like it could be solved if chafa is complied with cygwin.
The text was updated successfully, but these errors were encountered: