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

docs: replace redirection with tee command with sudo for file creation #1557

Closed vostok92 closed 3 months ago

vostok92 commented 4 months ago

This pull request addresses an issue where using sudo-prefixed echo does not grant elevated permissions for the subsequent redirection operation, resulting in a failure to write files under /etc/apt. By replacing the redirection with a sudo-prefixed tee command, this change ensures that files are written with root privileges, effectively resolving the permission issue. This modification is essential for operations requiring write access to protected directories.

jkbrzt commented 3 months ago

Thanks, @vostok92!