Slacker News Slacker News logo featuring a lazy sloth with a folded newspaper hat
  • top
  • new
  • show
  • ask
  • jobs
Library

Comment by FeepingCreature

5 years ago

Instead of sudo sh -c to sudo the redirects, consider echo 'abcde' |sudo tee /proc/bla. Less nesting :)

2 comments

FeepingCreature

Reply

npongratz  5 years ago

Do you mean less syntactical nesting? The pipe to sudo tee creates a new child shell, just as sudo sh -c does.

  • FeepingCreature  5 years ago

    Yes.

Slacker News

Product

  • API Reference
  • Hacker News RSS
  • Source on GitHub

Community

  • Support Ukraine
  • Equal Justice Initiative
  • GiveWell Charities