7 ms·
>Huh? Okay - think Cygwin, except: Oh boy, another one of these. Cygwin is useful because it provides a POSIX C API on Windows. It is not useful because of its
by Sir_Cmpwn 11y ago
>Huh? Okay - think Cygwin, except:
Oh boy, another one of these. Cygwin is useful because it provides a POSIX C API on Windows. It is not useful because of its shell and coreutils. And saying it uses "pure ES6" is stretching it - it's using the plain ES5 Node.js require/export patterns instead of ES6 modules.
>1/15th of the size [of Cygwin]
Haha, and 1/100th the functionality
- TickleSteve 11y agoCant upvote you enough.... Also... Node... Huh? seriously? replace a siongle DLL with Node.JS is simplifying it??
- Smudge 11y agoSimpler is better. Cygwin is overkill unless you are trying to mimic your exact non-Windows environment, and it doesn't mix well with Windows' vanilla CMD environment. For those of us who want to be working with more Windows than UNIX, but who are used to standard coreutil commands, 1/100th the functionality of cygwin actually sounds kind of great! Not saying that the commands need to be written in JS, but it seems like every language gets at least one coreutils implementation, so why not? So much negativity around here. Honestly I find it pretty neat that JS has come this far.
- throwaway2048 11y agonode.js is not simple or even simpler
- recursive 11y agoHowever, I already have it.
- capote 11y agoYou already have a processor too, and something running directly on that is, in fact, more simple.
- recursive 11y agoIt's more simple from the point of view of the processor, I suppose, but that's not a useful metric for me.
- StavrosK 11y agoIs your unit of simplicity really "I already have this installed"? Because then this hello world line I just wrote is more complex than your OS.
- joesb 11y agoFrom the point of view of the user, yes.
- recursive 11y agoMaybe simplicity isn't exactly what I'm talking about, but yes. In fact, I couldn't run your hello world without running my OS. So from a practical point of view, me running your hello world has a dependency on my OS. From that perspective, it's easier for me to run my OS than your hello world.
- StavrosK 11y agoI see. So you have these coreutils installed? Because if not, they're exactly as "simple" as cygwin, which is also not installed.
- recursive 11y agoNo, I don't. I have a vague recollection that cygwin was a huge and confusing monolith, but I haven't looked at it in years. This new javascript thing sounded more straight-forward. It's not really objectively supported. I don't even like javascript.
- umanwizard 11y ago
- metalock 11y agoYes, but - when you hit some bug or just need some specific combination of commands, there would be thousands posts on the web that explain how to do on unix that will work in Cygwin. Will they work in this environment?
- recursive 11y agoThe question is hypothetical. Sometimes the answer would be yes. Sometimes the answer would be no.
- StreamBright 11y agoI also have Fortran, Cobol, SWI-Prolog, OCaml, Elixir and Erlang on my computer, so I guess we need to re-implement core utils in these languages too. Using the followings in any technical arguments is just plain stupid: - it works on my laptop - but I already have it
- goldbrick 11y agoUsing a node script doesn't munge the rest of my shell environment. Cygwin, on the other hand...
- manyxcxi 11y agoIs this indicative of what's going on in the JS world today, with all the churn of packages and libs? Does it boil down to being sucky and not useful if it isn't written in ES6/TypeScript/Whatever and not invented by your team? Why do the other things suck because they're not this? EDIT: I've said it on other threads- I like the creativity and exuberance in the JS community. I'm not putting it down. There's just a lot of churn/NIHS. (I didn't seem to be getting downvoted, but I also want to be clear that I'm not putting the community down) END EDIT I think it's a cool excercise. Why would I ever want to use this in the way it is saying it should be used? Why would I ever use this period?
- AnkhMorporkian 11y agoIn instances like this, there's no issue with it being ES5. However, in the web world, ES6 modules have a huge (pardon the pun) advantage that's just being realized. Because of the static nature of ES6 imports, you can eliminate unused code when you package it all together. The newest Webpack versions and Rollup are both taking advantage of this, and it can result in huge savings in filesize. For example, lodash is a large library with hundreds of methods, and a lot of the time people only use 3 or 4 imports from it. If you use an ES5 version, you'll get all of those functions in a compiled bundle no matter what. If you use an ES6 version with Webpack 2, all the methods you use will end up being the only ones that are actually included in the final code.
- elmigranto 11y agoI imagine most libraries has some common functions that ones from public API rely on (and of course some exports can be used within module itself). Let's say you never import `helperX` and `helperY` from a library, but you import `usefulFunction` which relies on `helperX`. How would webpack know to exclude `helperY` but not `helperX`? Unless it does some kind of code analysis, or lib is split in "module per function" or similar manner, I can't really see a way to achieve it. And if library is common core plus a bunch of modules per function it exports, how is that different in CommonJS versus ES6 modules? Am I missing something?
- hasenj 11y agoI suppose in this case "less is more". More often than not, if I'm working on a windows machine, I'm not programming in C. I'm probably working on something in C# or Java. I don't care about the C API. I just want the terminal to work in more or less the same way it does on linux/osx.
- debacle 11y agoFor my purposes, I don't need a POSIX C API. What I need are the shell commands that I commonly use as my IDE to be available on Windows without a massive hack. Cash seems to be right up my alley, and I'm excited for this.
- Sir_Cmpwn 11y agoI'm not saying that it's not without use-cases. I'm saying the readme is pompous and overstates its usefulness and was clearly written by someone who doesn't have a clue about the tools they're replacing.
- rplnt 11y agoIf you have npm already.. I guess? I personally haven't had a windows machine without git in years. Distribution for windows includes somewhat proper shell with unix utils. I can use the same .bashrc I have on my linux machines, write commit messages using vim, have colors in the terminal, etc...