News for hackers. Stuff that matters.
Re:Show HN: Curl https://ec2.shop by kureikain on Tuesday June 30, 2020 @11:50AM (#23691273)
Great idea.

I just implement it: https://github.com/yeo/ec2.shop/commit/ab258aef3ac2ad3d45b26...

Now by default it's text mode, so request by http client library or tool like curl, wget, httppie all get text bersion.

Only when detecting `Accept` contains `html` and user agent is safari/chrome/firefox etc it send html version.

Re:Show HN: Curl https://ec2.shop by karmakaze on Tuesday June 30, 2020 @02:12PM (#23692977)
There should be no reason to check user agent if already checking `Accept`. That's usually more for browser quirks or allow/blocking.