chiark
/
gitweb
/
~cjwatson
/
bin.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
715f8ee5a4905ee3804c3f290fff9d65954a4a9b
[bin.git]
/
tiocnotty
1
#! /usr/bin/python3
2
3
import fcntl
4
import os
5
import sys
6
import termios
7
8
try:
9
with open('/dev/tty') as tty:
10
fcntl.ioctl(tty, termios.TIOCNOTTY)
11
except IOError:
12
pass
13
14
os.execvp(sys.argv[1], sys.argv[1:])