Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I create courses that are taken on Linux and Windows.

On one hand, I love that curl is aliased to iwr, since I can tell learners to run a curl command without arguments and trust that it will work cross platform

On the other hand, iwr is a cmdlet that shortcuts the System.Net.WebRequest .NET method, which is very, very different from libcurl.

For example, the cmdlet uses one of its properties to obtain bytes downloaded so that it can display a progress bar. Unfortunately, doing this seems to be blocking, as downloads complete SIGNIFICANTLY more quickly if you add -NoProgress to the command. This break cross platform compatibility, however, which adds complexity during course development (more tests, more copy, etc)



I've been using iwr for years and didn't know that the progress bar added latency! Much appreciated.

My main point to the OP was more that it's just an alias, you can remove it and use real curl if you want.


No problem! I definitely recommend using the real thing where possible!




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: