5 ms·
Say goodbye to the MS-DOS command prompt
- andreiw 10y agoExcept it is not the MS-DOS prompt (unless you actually ran command.com, via the NTVDM). It may look like a duck, quack like a duck (sort of), but it really was just another Win32 (albeit console) program.
- ohjeez 10y agoIf you could get more work done at a command line than with a GUI, it's duck-enough for me.
- theandrewbailey 10y agoExactly. It's not DOS, it's another interface Windows. It tell you so on it's first line! Everything you run in it won't print "This program cannot be run in DOS mode." and exit.
- cestith 10y agoThankfully FreeDOS and DOSBox exist, so all those hundreds of batch files each of us old DOS hands has lying around won't go to complete waste.
- Silhouette 10y agoI have very mixed feelings about this. On the one hand, the Command Prompt in Windows has always been something of a second-class citizen, a poor imitation of the power user shells of the UNIX/Linux world. It was long overdue for an upgrade. PowerShell is, no doubt, more powerful, and for professional Windows sysadmins with the time and inclination to learn it, it's probably been the default for a long time. On the other hand, there's a reason the traditional command prompt and batch files have lasted so long: for a lot of basic purposes, they work just fine, and many people know how to use them. Among those who aren't professional Windows sysadmins, I know very few people who seem to use Powershell at all, probably not helped by the fact that it has some of the worst documentation in computing history and is far from intuitive for anyone familiar with either the traditional Windows command prompt or something like bash. I'm still not at all comfortable with the idea that with Windows 10 you'll essentially just wake up one morning and find something you've been using happily for literally decades isn't there any more and pressing the keyboard shortcut that got you want you wanted last night doesn't do so this morning. Regardless of whether this particular change can be turned off, at least for now, this still seems a very dangerous policy in general.
- WorldMaker 10y agoFirst of all, all that is happening is the default is swapping. You can still swap back if you really must. Also, PowerShell runs .bat batch files just fine, for those that were wondering. I don't think PowerShell has any worse documentation than bash: most commands support -? and/or -h just like they do everywhere else. Or there might be extra help for a command in Get-Help, which is very similar to unix man (and aliased to it if you have the have the habit to just man commandname). Don't know the command you want? Get-Command lists them and the you can Get-Help about it. Beyond that there's definitely a learning curve to get used to the common verbs and some subtle syntax differences to bash, but that's not much different from learning the differences between bash and zsh or csh or emacs... On this front I can point you to a lot worse documentation than PowerShell's in the deeper, weirder *nix command shells. Edit: Removed asterisk interpreted as emphasis.
- Silhouette 10y agoFirst of all, all that is happening is the default is swapping. You can still swap back if you really must. Sure, but that's not really my point. No-one who is seeing the default swap had much if any say over whether the option to swap back would be provided, nor will many if any of those people have any say over whether and when the alternative will be deemed too much trouble to maintain and removed entirely. I remember painfully well my first experience with Powershell, back when it was new. I thought I'd give it a try, so I opened a shell window and tried a few commands. What happened next went something like the following. I'm actually reproducing this as I type this post, following roughly the same process using Powershell as installed on my Windows PC today, just to make sure I'm not talking complete rubbish here and it really is as bad as I remember... dir OK, great, I still get a directory listing. I'm in my home directory and lots of the useful subdirectories are hidden by default. No problem: dir /a What, why is that an error? Oh, this isn't really dir as I know it, and / is now a path separator, reversing two decades of Windows using \ for that purpose. OK, maybe it's more like bash then? dir --help No, that's an error as well. OK, let's try something else: help If you've ever tried that in Powershell, you'll be aware that it produces one of the most unhelpful help pages ever written. Even a simple section about what to read to learn about Powershell is full of jargon that no-one who didn't already know Powershell would necessarily understand. What is a cmdlet? Is that like a batch file? Where did all this stuff about properties and methods on objects come from? I'm trying to get a directory listing, not write a GUI in Java! At least it finally tells me the magic syntax to get help on any given command: -? dir -? Wait, what? I asked about dir, and it's telling me something about Get-ChildItem. Except it's not really, because all it tells me is some syntax for something I didn't ask about, with no indication of why it's relevant or what any of the options (I'm assuming) actually do. But after a screenful of more jargon I don't understand, it says something about how to get more information, so let's try that. Oh, I still can't copy and paste like most UIs had since the 1990s. OK, back to typing out tedious commands full of variations on what I actually want to ask about the old-fashioned way: get-help Get-ChildItem -detailed Oh, look! Several screens of further jargon, which apparently still don't support paging like any decent CLI since the 1990s either! But at least it tells me that what I want is the -Force option. Maybe. Because even the brief description of that option manages to use jargon I don't know and refer me to yet more help pages. And why on earth would an option that is normally used to override confirmation prompts when doing something destructive apply to a dir command? Somewhere around this point, if memory serves, I stopped, presumably fearing that I would lose the will to live if I carried on much longer. But again, I wasn't particularly trying to make the point here that Powershell is a textbook example of how not to do UI design, though it is and I might have been. My real point was that taking a tool that has been useful for 20 years and replacing it literally overnight and without prompting with a radically different tool that is also demonstrably inferior in some ways is a really, really dumb idea.
- icc97 10y agoI'm really sad about this. I grew up with useless crappy windows games and messing around in the DOS prompt. I love the fact that I'm still using it. I know batch file programming is ridiculous, some of the most mental looking code I've written is part of that. But I get some masochistic pleasure from using it, I've automated tons of my work through it. Much cudos goes to Rob van der Woude's batch scripting site [1]. But finally, finally they did some really nice updates to the DOS prompt in Windows 10 so that it fills the screen properly and line wraps correctly. In the DOS prompt I've got: - SSH (natively compiled) - Pretty much all the linux command tools I want grep, cat, sed etc (thanks be to Git SCM and all it's precursors e.g. GOW) - Vim - Lovely consolatas mono font - which gives lovely crisp font rendering - better than any of the DOS 'replacements' - Rather lovely Solarized dark colours - GNU Readline [2] (hitting tab gets you a slash at the end of the directory, yay!) - Chocolatey package management Seriously, the DOS prompt can be quite lovely to use [3] I know Powershell is all shiny and new with added .net up it's arse, but I don't need it and it's not what I was typing in as I grew up. I even went about changing all my .bat files to .cmd files to be ultra modern this year. I think there'd be uproar in the Linux world if bash was 'put out to pasture' (reminds me of the horse in Animal Farm) as is happening to DOS. [1]: http://www.robvanderwoude.com/ [2]: http://mridgers.github.io/clink/ [3]: https://dl.dropboxusercontent.com/u/7765571/images/screenshots/dos.png
- voycey 10y agoCare to share what tools you installed all of that with? I think you can still do all of that in Powershell...
- icc97 10y agoI'm sure you can do it all with Powershell, I just don't want to switch :) But as for getting it all installed, it's pretty easy: 1. Chocolatey [1] 2. Git chocolatey package [2] (gives GNU tools, SSH - there is also a separate OpenSSH package from MS [6]) 3. Vim chocolatey package [3] 4. Consolas font (just change the DOS window properties) 5. Solarized colours [4] 6. GNU Readline (clink) [5] [1]: https://chocolatey.org/install [2]: https://chocolatey.org/packages/git [3]: https://chocolatey.org/packages/vim [4]: https://github.com/neilpa/cmd-colors-solarized/ [5]: http://mridgers.github.io/clink/ [6]: https://chocolatey.org/packages/openssh Edit: fixed formatting, added OpenSSH package link
- voycey 10y agoI just find everything so convoluted in Powershell, don't get me wrong its much less painful than using cmd but compared to a bash shell I find myself tearing my hair out! I think things would be easier if I was a .NET coder but im not and I miss the basic simplicity of things like `where` from bash vs having to create an entire script to just find executables on the path!
- flukus 10y agoI'm a .net coder, it's no better. I still use cygwin.
- voycey 10y agoCheck out the new Ubuntu Bash thing on Windows 10, its pretty impressive for most things and doesnt have the idiosyncrasies that Cygwin has :)
- flukus 10y agoI have, I stick with cygwin because it has better interoperability with the rest of windows. Ubuntu bash is more like using a virtual machine.