News for hackers. Stuff that matters.
Re:Microsoft’s PowerShell Core Offers Cross-Platform Automation by AnIdiotOnTheNet on Monday January 22, 2018 @01:16PM (#16206525)
Powershell has short aliases (and you can define your own too) for the most frequently used commands, and I find the process of reformatting text output between commands to get them to pipe to each other and not choke on formatting differences more cumbersome and time consuming than any extra verbiage added by powershell.
Re:Microsoft’s PowerShell Core Offers Cross-Platform Automation by smacktoward on Monday January 22, 2018 @03:10PM (#16207457)
But this can cause other problems. An example would be the way that Powershell for a long time aliased the Invoke-WebRequest cmdlet to both 'curl' and 'wget'. This was supposed to be a convenience feature, but it broke all sorts of scripts that were written to use "real" curl or wget because Invoke-WebRequest didn't accept curl or wget option parameters (oops).

They've fixed this in recent versions by shipping actual curl binaries, but it's a useful illustration of how just aliasing popular shell commands to their Powershell alternatives isn't necessarily helpful.

Re:Microsoft’s PowerShell Core Offers Cross-Platform Automation by contextfree on Monday January 22, 2018 @05:41PM (#16208758)
invoke-webrequest has a "native" short alias too: iwr. I like these native aliases because they use a consistent pattern of abbreviations for verbs and nouns, e.g., the same "i" for invoke is used in icm = invoke-command, iex = invoke-expression, ihy = invoke-history, etc.; then if you look at the nouns in one of those others (since invoke-webrequest is the only "webrequest" cmdlet), they're also consistent, e.g., gcm = get-command, shcm = show-command, trcm = trace-command.
Re:Microsoft’s PowerShell Core Offers Cross-Platform Automation by contextfree on Monday January 22, 2018 @01:52PM (#16206841)
Most of the aliases use a consistent naming pattern too, which I appreciate.