blob: d5eb34edf340b3dc18dbd4197e9d35fb49c8c14b (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
|
termios sets the stdin terminal to raw
make sure to use read/write syscalls, these are non blocking, and will not mess
up the output of things.
now all line discipline is handled by the pty
-------------------------------=[Controlling TTY]=------------------------------
Forked bash process makes itself a session leader, then sets the pty as the
controlling tty
It now acts as a bash
----------------------------------=[Resizeing]=---------------------------------
SIGWINCH hook, very simple
-----------------------------------=[Testing]=----------------------------------
fg/bg ctrl-c ctrl-z all works
cmus, bcmus, all work
-------------------------------=[Useful Commands]=------------------------------
ps l
tty
infocmp
|