3 ms·
I think it's a limitation more on the windows batch end. As mentioned, it's tricky for historical reasons. Powershell would be closer to Bash, functionally spe
by badloginagain 10y ago
I think it's a limitation more on the windows batch end. As mentioned, it's tricky for historical reasons.
Powershell would be closer to Bash, functionally speaking. An adapter between the two would be more functional- however doesn't satisfy the point of batsh, which assumes cleanish-builds of the OS in question.
- stephengillie 10y agoPowershell introduces more complications, with functions like Invoke-WebRequest being given the alias "curl". At a minimum, you would get a type validation error, as Invoke-WebRequest by default gives back headers and other data as objects inside a larger object, not just the content string that curl.exe defaults to returning. This should work in both bash and PS, with different results: > curl HTTP://example.com > file.html
- Hondor 10y agoIsn't that just what a compiled language would sort out for you? On Bash it'd compile to curl HTTP://example.com > file.html and on PowerShell it'd become (curl HTTP://example.com).Content > file.html
- niutech 10y agoThere is an "adapter" between PowerShell and Bash - Pash (http://pash.sourceforge.net http://pash.sourceforge.net)