Just another reason to stay away from Windows as a platform. Windows 10 is a moving target if you are trying to work with it.
If you're not a fan of change, I feel like software development probably isn't the right career choice.
Microsoft Replaces Command Prompt with PowerShell in Latest Windows 10 Build
71–80 of 350 posts
Re: Microsoft Replaces Command Prompt with PowerShell in Latest Windows 10 Build
#72Something that irks me is how PowerShell’s default aliases take precedence over binaries in the PATH. To be able to use the GNU utils, you have to put this in your profile.ps1 : Remove-Item Alias:cat Remove-Item Alias:cp Remove-Item Alias:curl Remove-Item Alias:echo Remove-Item Alias:ls Remove-Item Alias:man Remove-Item Alias:mv Remove-Item Alias:pwd Remove-Item Alias:rm Remove-Item Alias:wget
Re: Microsoft Replaces Command Prompt with PowerShell in Latest Windows 10 Build
#73Btw did anyone noticed that in windows 10 you can resize cmd.exe to more than 80 characters width! When I first saw it I almost cried.
Re: Microsoft Replaces Command Prompt with PowerShell in Latest Windows 10 Build
#74Earlier quoted context omitted.
How would an alias work otherwise? That's pretty much the way it behaves in Unix, too (e.g. 'ls' in most default configs). Although I'd still consider curl/wget to be specific tools and not generic commands, so emulating them seems a bit weird.
The point is that they're defined by default. See this story for more background: https://news.ycombinator.com/item?id=12319670 Edit: the RFC intended to address the curl author's issue was rejected. https://github.com/PowerShell/PowerShell-RFC/blob/master/X-R...
Re: Microsoft Replaces Command Prompt with PowerShell in Latest Windows 10 Build
#75Earlier quoted context omitted.
Seriously? I wonder how they managed to do that, i am sure that required a whole engineer team for a whole month!
https://technet.microsoft.com/en-us/library/dn167709.aspx > Every idea for a feature starts out with an imaginary deficit of -100 points. That means it has to demonstrate a significant net-positive effect on the product as a whole in order to emerge as being truly worthy of consideration.
I still dont understand how this was not "fixed" years ago, sure some config windows have fixed widths because it makes sense, but something as a terminal obviously needs the ability to grow (or shrink), especially after they introduced sticky windows and people actually used "tiling"
Re: Microsoft Replaces Command Prompt with PowerShell in Latest Windows 10 Build
#76"Typing cmd in the run dialog will launch PowerShell as well" What? I'm a big PowerShell fan, but I see the need to keep cmd around for a while. Clobbering it before it's phased out seems problematic.
Re: Microsoft Replaces Command Prompt with PowerShell in Latest Windows 10 Build
#77Something that irks me is how PowerShell’s default aliases take precedence over binaries in the PATH. To be able to use the GNU utils, you have to put this in your profile.ps1 : Remove-Item Alias:cat Remove-Item Alias:cp Remove-Item Alias:curl Remove-Item Alias:echo Remove-Item Alias:ls Remove-Item Alias:man Remove-Item Alias:mv Remove-Item Alias:pwd Remove-Item Alias:rm Remove-Item Alias:wget
Re: Microsoft Replaces Command Prompt with PowerShell in Latest Windows 10 Build
#78Personally I want to use PowerShell. The show-stopper for me is that I cannot set default encoding for output redirection (>) to ascii/utf-8. This is so important for things like Google Code Jam, etc.
_________________
¹ The redirection syntax cannot easily accommodate an encoding, so in general you cannot really use it everywhere anyway. I often need to use the system's legacy codepage instead of Unicode, so UTF-8 by default would be just as useless there. GCJ, however, could just accept text in any common encoding instead of insisting on ASCII. Detecting UTF-16 isn't hard, even though common Unix tools tend to treat it as arbitrary binary data instead of text.
Generally I'd say > is a convenience feature more than an actually useful construct, at least in a shell like PowerShell. On Unix-likes > simply dumps bytes since that's what the shell is built around. For PowerShell you could just as well say you'd dump CLIXML instead, since the shell works with objects. Since you have a few valid options you could either try to shoehorn them into the syntax, either with various funny characters
Get-Data > data-as-utf8.txt
Get-Data >@ data-as-clixml.xml
Get-Data >% data-as-utf16.txt
...
or add another expression somewhere Get-Data > data-as-utf8.txt,[Text.Encoding]::Utf8
all of which are options I'd say don't really fit into PowerShell, nor should they be entertained. Does it really matter whether the last part of a pipeline is a redirection operator or just a terminating command that writes the data to a file? Conceptually I'd say having the pipeline end in a pipeline element instead of something entirely else is preferable since it reduces the number of distinct concepts.Re: Microsoft Replaces Command Prompt with PowerShell in Latest Windows 10 Build
#79By the way, where does the capitalized kebab case come from? Prior art or just Microsofts general hankering for capitalization (e.g. C#s Class.DoSomething() vs Java's Class.doSomething())?
Re: Microsoft Replaces Command Prompt with PowerShell in Latest Windows 10 Build
#80Earlier quoted context omitted.
How is that any different from Linux distributions camping their default shell? Like back when debian changed their default shell to dash I don't remember anyone saying you should stay away from debian, even though it broke a lot of existing scripts.
That's a bit different. The change only exposed that some scripts were already broken and worked by accident. Specifying that your script should be run with #!/bin/sh and then using bash syntax is what broke them. It's a bit like naming your files something.c, writing the code in C++ and compiling with `cc` just because `cc` happened to be linked to `c++` on your system. It will work for you, but don't be surprised w…