httpie / cli

🥧 HTTPie CLI — modern, user-friendly command-line HTTP client for the API era. JSON support, colors, sessions, downloads, plugins & more.
https://httpie.io
BSD 3-Clause "New" or "Revised" License
32.67k stars 3.68k forks source link

Update README.md #1545

Closed geomat0101 closed 3 months ago

geomat0101 commented 6 months ago

existing advice is broken, results in 'bash: /etc/apt/sources.list.d/httpie.list: Permission denied' because it is trying to redirect the output of the sudo command outside privileged context.

Converted it to a subshell invocation

mikelolasagasti commented 6 months ago

There's an alternative way to achieve the same result that I find more concise and readable. Instead of using the sudo sh -c approach, you could consider the following:

echo "deb [arch=amd64 signed-by=/usr/share/keyrings/httpie.gpg] https://packages.httpie.io/deb ./" |sudo tee -a /etc/apt/sources.list.d/httpie.list
jkbrzt commented 3 months ago

Fixed via #1557. Thanks!