9 ms·
Gow - The lightweight alternative to Cygwin
- msluyter 14y agoShell window from any directory: Adds a Windows Explorer shell window (screenshot) so that you can right-click on any directory and open a command (cmd.exe) window from that directory. Hmm... but.... why would I wan't to do that? If it opened a window running bash that'd be interesting, but I never ever want to run cmd.exe if I can possibly avoid it. Perhaps that's just me though... can anyone comment on how this compares to cygwin, generally? I see that it's smaller but I don't find cygwin's footprint especially troubling.
- ordinary 14y agoWindows provides this feature natively, since Vista or 7 (I don't remember which): when you shift right-click in an explorer window, the option 'Open command window here' appears.
- dspillett 14y agoI'm not seeing that on this fairly fresh Windows 7 "Pro" install. I have added the feature to numerous Vista and XP machines, it is easy enough to add manually though there are many utils that will do it for you, but I can't say I've never seen it present by default.
- bdunbar 14y agowhy would I want to do that I would want to do that to run a batch file, see the output. I have, for example, an integration server, Server 2003. It keeps batch files for XML to JDE eleventy directories deep. It is sometimes helpful to exec these manually to see what the trouble is.
- j-kidd 14y agoIf you don't need to run cmd.exe, then this is likely not for you. On Windows, I deploy native 64-bit Python, and the application has quite a few command line pyramid scripts, which works perfectly fine with grep, cut, sed, sort, etc from gnuwin32. Don't see the need for cygwin.
- lnanek2 14y ago> If it opened a window running bash that'd be interesting Cygwin has a package for that called chere. The whole point of this other thing is that it tuns in cmd.exe, so complaining that it opens cmd.exe is really complaining about the main thing, not just this one feature...
- aeurielesn 14y agoI do have Cygwin installed but anyways I have been using Gow for a couple of months already. Thanks to it I can still run `grep` and `less` when I am using a normal DOS terminal (or even 4nt) for example when I need to run a build script. There is still some grasps with the shipped versions of the tools i.e. missing some parameters and not having `awk` is a bummer.
- jorgem 14y agoI don't understand. I put cygwin in my path, and I can run grep/less from a normal DOS terminal.
- TylerE 14y agoYou can run into some weirdness there with commands that exist in both DOS and Unix, if you aren't careful. echo, find, sort, etc.
- dredmorbius 14y agoNo issues with terminal handling? I've always found the DOS terminal to be very dissatisfying. I recall when I first encountered WinNT40WS, which a colleague had billed as "a multiuser OS with a full shell", that, other than the lack of a full shell and useful utilities (I rapidly discovered MKS, UWIN, and Cygwin, followed very shortly thereafter with Linux, which supplanted the original OS a few months later), was the absolute crap terminal support. That this is still the case (from my relatively minimal experiences/exposure to Win7) can just be piled on top of the large heap of embarrassments Microsoft have produced). When installing Cygwin, among the first things I do is create a shortcut using the rxvt (non-X) client, with a command to launch a log-in shell session, with appropriate font and color settings. You can even run Windows commands and shells within this, though of course, they will also break in some full-screen instances. Mostly I just avoid the whole problem. Pretty successfully for months at a stretch these days.
- javanix 14y agoDoes this allow you to run GCC or anything compilers on Windows? I thought that was the main draw of Cygwin.
- mwexler 14y agoThat's one of the draws, sure. But it's also nice to be able to replicate shell scripts or clever unix file hacks with a complete set of syntax compatible utilities so that less "translation" needs to happen. If you don't need all that back-end compatibility stuff (running gcc, etc.), this can be a much quicker and easier approach.
- jmatt 14y agoCheck out msys/mingw. It's a challenging setup, minimal and supports gcc. Key difference with cygwin: no attempt at posix compliance. http://www.mingw.org/ http://www.mingw.org/
- tom9729 14y agoMinGW: http://sourceforge.net/projects/mingw/files/ http://sourceforge.net/projects/mingw/files/ Console2: http://sourceforge.net/projects/console/ http://sourceforge.net/projects/console/ MinGW comes with an installer that gives you GCC. Make sure you install MSYS as well (comes with bash, etc). Add the bin directories to your %PATH% when you're done. Then set Console to use bash as your default shell, and you have a pretty close setup to the command-line experience of Linux/Mac.
- lucian1900 14y agoIndeed, that setup works pretty well.
- warmwaffles 14y agoGit integration? I have git bash but I'd like to have more unix stuff than what is offered there
- atilimcetin 14y agoThat's great! But it seems it's more like GnuWin32 rather than Cygwin. Cygwin provides very compatible POSIX system call API (through Cygwin DLL) in terms of Win32 system calls.
- m_rcin 14y agoagain? https://news.ycombinator.com/item?id=3312009 https://news.ycombinator.com/item?id=3312009 I don't see any major updates on Github since the project was uploaded in 2010. Cygwin is meant to be complete POSIX system, so GOW seems to be rather an alternative to MSYS from MinGW.
- stagas 14y agoSo it's been posted again, 186 days ago. So what? Not everyone visits HN every day, and not everyone's been here since the beginning. Reposting useful stuff for those who might have missed them is a good thing in my book.
- ta12121 14y agoThis is how everyone defends reposts, but for an experienced engineer that's been reading HN for a while it means the front page is often full of uninteresting links.
- stagas 14y agoThat's a fair argument. A solution would be to increase the initial weight for same link posts every time they're posted. That would decrease the time they spend in the front page exponentially. You could easily bypass this, of course, but I don't think most people are trying to hack the front page, they just found something interesting and they're sharing it with us.
- ma2rten 14y agoYou actually can only post every link once.
- chc 14y agoI'm pretty sure this is wrong. I think what you're talking about is HN's filter that prevents you from posting a story whose URL is identical to the URL of a story that's currently in memory. If you try to submit a URL that's already in memory, it gets converted to an upvote for the original. That doesn't prevent you from either posting the exact same URL once the original story has been purged from memory (probably after a couple of weeks) or posting a slightly different but completely equivalent URL. For example, IIRC the following are all counted as different URLs: • http://google.com http://google.com • http://www.google.com http://www.google.com • http://google.com/ http://google.com/ • http://www.google.com/ http://www.google.com/ • http://google.com http://google.com? • http://www.google.com http://www.google.com? • http://google.com/ http://google.com/? • http://www.google.com/ http://www.google.com/? I imagine https:// https:// would add eight more variants, but I haven't ever heard of anyone trying it in real life.
- bhousel 14y agoWithout a package manager, I really can't see myself using this. Cygwin + apt-cyg is just easy.
- bostonvaulter2 14y agoOh, this is the first time I'm hearing of apt-cyg. It looks really useful.
- scribblemacher 14y ago+100 for introducing me to apt-cyg!
- cowmix 14y agoHoly crap. apt-cyg.. where have you been for the past 13 years!
- strictfp 14y agoCan we go together and convince the stubborn Cygwin-devs to PLEASE integrate this into mainline? I've tried a couple of times to convince them that we need something like apt-cyg, and lots of people keep trying, but they just won't budge. See the discussion here: http://groups.google.com/group/apt-cyg-discuss/browse_thread/thread/aba973fd559cdfd http://groups.google.com/group/apt-cyg-discuss/browse_thread...
- lloeki 14y agoLike 10 years ago, I was poking them at the idea of having some command line support for package installation instead of having to go through the brittle setup.exe to install/update packages... You can make an educated guess at the answer to anything related to non-retarded package management.
- deleted 14y ago[deleted]
- dredmorbius 14y agoOMG I love you. I haet haet haet haet haet the f^cking cygwin "Setup.exe". The cygwin devs are being absolutely butt-retarded for failing to integrate this.
- andrewcooke 14y agoso what's the advantage over cygwin? is this intended for people with really small disks?
- rwallace 14y agoCygwin goes to heroic lengths to try to turn Windows into Unix; from what I've heard, it even splices a DLL into every process on the machine; if you want a less intrusive solution that just gives you a Unix utilities under Windows, Gow looks good.
- andrewcooke 14y agoany chance of a reference for "splices a DLL into every process on the machine"?
- rwallace 14y agoAfraid not, I forget where I heard it. I ran a Google search just now, though, and found a few pages such as http://forum.bitdefender.com/index.php?showtopic=15070 http://forum.bitdefender.com/index.php?showtopic=15070 which suggest Cygwin is innocent of such behavior and what's really going on is Cygwin needs a fixed DLL address (only for programs linked against it) and this is not compatible with some of the more intrusive antivirus programs that do inject a DLL into every process.
- dredmorbius 14y agoCygwin processes run through a shared DLL, of which one significant consequence is that all Cygwin processes on a machine apparently share some memory/process segments, making crypto and SSH commands less secure than they might be elsewhere. That said, the heroic efforts to turn Windows into Unix, when on the rare occasion I find myself stuck in a Windows instance, are very highly appreciated. At one point in my life, I was taking advantage of this to run X on my Linux box (cleaner and a few additional features that Windows didn't offer), with tunneled SSH to Windows to run, among other things, some Windows-based applications (which retained enough commandline features to be usable in this fashion) in an environment which almost fully resembled Unix. It helped markedly for both productivity and sanity.
- mieses 14y agoCan it run sshd or rsyncd as a windows service?
- cowmix 14y agoNope. :(
- bdunbar 14y agoHave not tried - but it's on my todo list at work - turn rsyncd into a user-defined service? See Article ID: 137890 here: http://support.microsoft.com/kb/137890 http://support.microsoft.com/kb/137890
- dnewcome 14y agoI used to use CopSSH for running sshd on Windows. Worked pretty well from what I can remember. It's just cygwin+sshd packaged up nicely.
- drivebyacct2 14y ago1. There is already cmd.exe integration in Explorer. Hold Shift as you right click. 2. This doesn't look much like Cygwin. At best it's like MSYS with MinGW compiled tools. Either way, no package management, no auto updates.
- miles 14y agoAs others have pointed out, Gow isn't really a Cygwin replacement; it offers over a hundred *nix apps compiled as native win32 binaries. A similar project from yesteryear - might be of some small use to one or two people (max): The Berkeley Utilities - 40 unix commands ported to DOS http://web.archive.org/web/20090304003628/http://openetwork.com/berk.html http://web.archive.org/web/20090304003628/http://openetwork.... "The Berkeley Utilities follow rigorously the unix System V syntax and include all the options found on any unix system plus a few carefully chosen ones. They used to sell for $200 and are now free." Great documentation, but sadly no source.
- iki23 14y agoI'm using MSYS http://mingw.org/wiki/msys http://mingw.org/wiki/msys heavily, it has bash and all file and text processing utils. It's also distributed as a part of Git port http://msysgit.googlecode.com http://msysgit.googlecode.com. Lots of other utils can be also found in GnuWin32 http://gnuwin32.sourceforge.net/packages.html http://gnuwin32.sourceforge.net/packages.html. Btw, the sed in Gow would deserve update from 3.0.2 ;) https://github.com/bmatzelle/gow/wiki/executables_list https://github.com/bmatzelle/gow/wiki/executables_list
- cowmix 14y agoGow is great because the install time is much, much shorter than Cygwin. Cygwin is a beast. However, I don't see that Gow has been updated since the last time it was featured on HN.
- ta12121 14y agoI fail to see how this is interesting. There is already a well known alternative to Cygwin: MinGW/MSYS. Also, anyone looking for such a thing can find it with five minutes of googling.
- to3m 14y agoDon't fret - I found it interesting. I've been using GNU-Win32 for years; it's generally solid, and the CHM docs are nice, but there are some issues with it. But last time I was looking for a replacement, I couldn't find one! Gow looks like it might be just the ticket. As for MinGW/MSYS, last I looked, MSYS looked a bit incomplete for my purposes. I don't have any interest in or need for the MinGW gcc and autoconf bits, which tools looked to be its main advantage over GNU-Win32.
- j-kidd 14y agoI thought the same. Then I found that Gow is shipping way older versions for many binaries compared to GNU-Win32, and its patch.exe causes UAC prompt for non-administrators. GNU-Win32 is solid, integrates natively, and is good enough for deployment purpose.
- guelo 14y agoBTW, Windows PowerShell includes a bunch of unix aliases including ls, cat, cp, mv, rm, pwd, more, ps, man, mount, echo, diff. It is also very customizable, it became my standard windows shell when I discovered posh-git https://github.com/dahlbyk/posh-git https://github.com/dahlbyk/posh-git
- gemma 14y agoYeah, but the PowerShell output from those "aliases" doesn't match the *nix versions (e.g. ls), which drives me nuts.
- dredmorbius 14y agoIf Microsoft had wanted to do the Right Thing, they would have adopted the bash shell, and created a set of utilities providing access to services it doesn't provide. Currently, Bash (or something very bash-like) is The One True Shell for all Unices, Linux, MacOSX, and even (rootkit ant terminal app) Android. As well as zSeries and numerous other platforms with appropriate compatibility kits. Microsoft are ghettoizing themselves. It's a large, well-populated ghetto no, but I see a downward trend.
- flomo 14y agoThere is "SUA", but it's only available for the Enterprise & Ultimate Windows editions. (And supposedly going away entirely after Windows 8.) Shame it wasn't better integrated and packaged. http://www.suacommunity.com/sua.aspx http://www.suacommunity.com/sua.aspx
- Zuider 14y agoThere is also UWIN which emulates a full Unix environment for windows. It includes KSH. Its cc comand can work with a number of compilers including MinGW, and Visual C++. http://www2.research.att.com/~gsf/download/uwin/uwin.html http://www2.research.att.com/~gsf/download/uwin/uwin.html
- periferral 14y agono cron, no thanks
- encoderer 14y agoThe best lightweight cygwin alternative I could suggest to Windows users is... uhh... VirtualBox and Ubuntu!!!
- dredmorbius 14y agoFor an even more lightweight approach, you could strip out the VirtualBox.
- stagas 14y agoOpening a native console is notably faster and lighter than booting a VM. Interacting with real system files, network ports, etc. is also much more convenient and less error prone than setting up shared folders and other trickery.
- encoderer 14y agoIf you're doing any real work in a console on Windows then you're in a world of hurt. The console itself is just awful compared to what you have available on a real, POSIX-compatible OS (Linux, OSX, etc). This extends to SSH apps, too. Putty? Seriously? And implementations of tabbed and paned shells (the few you can choose from on Windows) are terribly ugly and clunky. Windows 7 (and presumably 8) is a fine OS. I really had no beef with it. But as an engineer I spend far too much time at a command prompt to ever consider going back. Also -- you don't boot your VM every time you want to use it. You keep it running in the background. Allocate 256MB of memory to it and forget it until you need to use a real shell.
- swah 14y agoPutty feels much lighter than Gnome Shell etc though.
- encoderer 14y agoLighter in what way? I don't necessarily disagree but when I think putty i think: No tabs and No panes so you're limited to using the OS window manager, and if you want to achieve multiple usable sessions at once you're going to have to arrange and resize these windows yourself or you'll have to use another 3rd party app. No integrated private key authentication. You have to use like 3 GUI screens (wha?!?!?) to set this up and then you have to run a 3rd party app like pageant. I had many other gripes before I switched (to a mac in my case) but I can't remember them anymore.
- mkup 14y agodoes it have fork(2) support? if it doesn't, then it's rather alternative to MinGW, not Cygwin
- zschallz 14y agoI miss andLinux and coLinux. Since using a 64 bit OS they no longer work, but they natively emulated the whole Linux kernel and offered a pretty integrated solution. Not lightweight by any means, but just what I wanted.
- uwin 14y agoNo mention of UWIN? Shame on you HN. http://www2.research.att.com/~gsf/download/uwin/uwin.html http://www2.research.att.com/~gsf/download/uwin/uwin.html
- jdboyd 14y agoI've long had poor feelings about Cygwin being slow and a poor solution. I wanted something that didn't try quite so hard to completely distance itself from Windows. So, instead, I've been using MinGW's msys project. I don't think it is quite as small, but it does offer a package manager. One small thing in msys that I particularly like is that I can do thins like: cd //server/share/some/directory I never saw powershell or cygwin do that. On Solaris I can configure automount to do that which is good enough, but just working is also nice.