Wednesday, January 25, 2012

[SOLUTION] screen -r : Cannot open your terminal ‘/dev/pts/0′ – please check.

as seen on http://blog.hbcom.info/archives/430

when trying to re-attach screen while sudo-ing you see:
$ screen -r
Cannot open your terminal '/dev/pts/0' - please check.


Solution:
Before starting screen type:
script /dev/null
And after that you can type:
screen -r
Only drawback is that you need to type one additional exit for script to terminate.

Sunday, January 8, 2012

How to change Debian's default editor

Command I keep forgetting no matter how many times I used it: update-alternatives
Full command to change command line text editor:

sudo update-alternatives --config editor