-
Notifications
You must be signed in to change notification settings - Fork 610
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
Windows build #92
Comments
Attempting to build on msys/mingw fails, because sys/wait.h does not exist on mingw. It appears to be POSIX-specific. Attempting to build on cygwin succeeds. However, tig is much slower than gitk. My startup time measurements, from the moment I press Enter until the whole screen is populated with the log:
|
0.15 running in cygwin is not a speed demon either. But it is much more than textual gitk clone so people could probably live with it. Maybe it's worth to write some guide on how to compile it on Windows? Or put up binaries somewhere? Ideally both. :) |
Compiling with cygwin is easy, you just need to install the package dependencies. I don't know the exact list, but it includes gcc, libncurses, autoconf and automake. Then, it's
Is there a faster textual gitk clone? Because that's pretty much exactly what I'm looking for. A text-mode commit tool that has keyboard navigation and allows adding individual files/chunks/lines would be great too. |
I had many problems with compiling because: But after solving those and installing some dependencies, it compiled nicely indeed.
I don't know other tools really. |
I think you shouldn't have those problems if you use the shortcut created by cygwin's setup tool to start cygwin bash. |
Regarding slowness, I remember a Cygwin user requesting whether it would be possible to avoid loading the commit diff each time the cursor is moved in the main view, since fork+exec can be slow in Cygwin. A lazy navigation mode which fixes this has been added in commit c0cb28f. What other speed issues are you seeing? Is it mainly at start-up time? You need to be more specific, if you want me to be able to do something about it. Also, version 0.15 is veeeery old (almost three years) and a lot of improvements in speed has been added. For example, as of commit 6d276a6, tig no longer asks for move/copy detection. |
Everything is slow. When the diff is open, it takes about a second for it to update after moving the cursor. You can actually see it drawing things on the screen, like on ancient monitors. However, I think most of this would probably be because curses on cygwin is slow, and cygwin is slow in general. Process creation is much slower on Windows as well - if gitk is using internal git commands (i.e. not via the git.exe / git.cmd entry point), it has an advantage. Ideally, a Windows port of tig would use something like libgit2 instead of spawning processes whenever possible. A compromise would be a mingw port, which would require replacing POSIX-specific APIs (such as sys/wait.h) with Windows ones. |
gitk is using git.exe provided plumbing for most but has a couple of tricks to speed up things that I didn't yet try to integrate into tig. Also, since gitk is shipped with git it can make assumptions regarding new git features which are faster. I have thought about switching to libgit2, but I do not have the time for such a task at this time. Replacing POSIX APIs should be pretty simple since all process management is done in one file: io.c. Based on this, I would say that the last option is preferable at this point. |
It's certainly not unusably slow for me (both 0.15 version that I was using until now and now also 1.0x). I would rather think it mostly has to do with git being slower on Windows than on other platforms. |
OK, I got the impression that tig was unbearably slow compared to gitk. |
Recently cygwin 64-bit was released (http://www.cygwin.com). I'd really like to use it because it seems to fix some git issues I'm having, but the list of packages for 64-bit version does not include tig. I've tried building it (which I do for 32-bit anyway to have the latest version) but I'm unable to do it due to configure script not finding ncurses. Did someone by any chance have stumbled upon this problem and knows how to solve it? I'm not fluent in make. I have libncurses installed. I think the problem might have something to do with there being no libncurses_w_ installed (or available) but I believe that in 64-bit mode, the libncurses is actually the version with wide character support so "w" shouldn't be needed, I think. (I'll provide more info later, after I retry my attempt) |
@rchl I will take a look tomorrow and see if I can get it to compile on Cygwin 64-bit. |
Actually I have tried again and succeeded without any problems this time. :) |
When new |
I do not maintain the tig package on Cygwin, so I believe you have to ask On Sun, Aug 25, 2013 at 7:29 AM, Dmitry Malikov notifications@github.comwrote:
Jonas Fonseca |
This avoids one fork+exec and improves the start-up time on Cygwin. References #92
Install tig1.2.1 on Windows with Cygwin http://www.tangrucheng.com/installation-tig-under-linux-and-windows-cygwin.html |
Closing this to clean up the issue database. Version 2.x has some improvements targeting Cygwin, however, any plans for Cygwin this version of Tig or any version for that matter should be discussed upstream. |
FWIW, tig is now offered by Git for Windows: https://github.com/git-for-windows/git/releases/tag/v2.14.2.windows.1 |
I'm happily using tig on Windows which I've installed together with Cygwin but that is pretty ancient version 0.15. There seems to be nothing newer available. Did it become significantly harder to build later versions so nobody did it? Or there is just no interest?
I wonder if something could be done about it. If not by the author then maybe someone else could contribute a build based on new code.
The text was updated successfully, but these errors were encountered: