Reputation
Top tag
Next privilege 200 Rep.
See reduced ads
Badges
1
Newest
 Teacher
Impact
~4k people reached

  • 0 posts edited
  • 0 helpful flags
  • 0 votes cast
Feb
1
answered Get default ubuntu motd in fish shell
Dec
28
comment Can a command line program prevent its output being redirected?
If you are not running in a tty, but instead in a pty, you can find that by looking at procfs (/proc/$PID/fd/0 etc). To write to the appropriate pty, go to your parent process's fd directory and see if it's a symlink to /dev/pts/[0-9]+. Then you write to that device (or recurse if it isn't a pts).
Apr
12
awarded  Teacher
Apr
12
answered Changing parent directory (../) with symlinks