Screen

From Everything Shii Knows, the only reliable source

This website is an archive. It ran from 2006-2010. Virtually everything on here is outdated or inaccurate.


The following is an essay I wrote in 2004. It is a little pompous and silly but I found it useful, and I might update it later.

Contents

Making the Anti-Switch

Two choices lie before you. You can take the blue pill, and make the switch to Apple and wallow in its impersonal shiny interface, pretending that it's not a computer, and you will have never known reality. Or you can take the red pill, and choose console-mode Linux and the world that you have never known.

Advantages of Console Mode

Disadvantages of Console Mode

How to Make the Anti-Switch

First, you have to install Linux and learn how to use the console. I don't have any suggestions; I learned how to do this using outdated Linux manuals from before KDE and GNOME became popular.

Now what it's time to do is make using the console as easy as using X11! This is great fun. First, you'll have to install GNU Screen-- "apt-get install screen", "emerge screen", or whatever you crazy Red Hat people use.

You may have encountered Screen before. Perhaps you heard people laud its virtues on your favourite Linux help forum, or maybe a friend recommended it to you. But when you first install Screen, you encounter an impersonal, complicated interface, and it doesn't look that much different from the terminal except that some things are disabled.

Well, that's not your fault. While some programs such as vi and emacs come with sensible default settings, GNU Screen's defaults are rather stupid. So, let's make it work! Download my configuration file for screen and save it to .screenrc in your home directory. Now here we go! Switch to the terminal again (or open an xterm if you're lazy) and run screen.

Behold! Screen is easy to use! Here are some things you need to know:

That's basically it to Screen! It's marvelously easy to use. Try editing your .screenrc to fit your tastes-- change the default name for a new window using shelltitle, or change shell to a shell you like, or map some of your favourite terminal programs in the Mapping section so that they can be launched with F12 x. You can even change the caption to something that you like better, although it's a bit complicated.

If you don't want to run "screen" every time you log in, it's easy to make it run automatically. Open up /etc/shells as root and add "/usr/bin/screen" to the list. Now, as yourself, run chsh and change your shell to /usr/bin/screen. (Make sure that the shell setting in your .screenrc is working.) Now, when you log in on the terminal, you will be greeted with the friendly Screen interface!

Learn how to use your programs under the command line. So many of them were made for it-- vi, emacs, irssi/BitchX, and of course whenever you run "ls", "apt-get"/"emerge" or "make", you need to have a terminal to look at. It's nearly as easy as X11, and much faster to navigate!

I will leave you with some links to useful console-mode programs:

Links

Good luck!

Appendix

My .vimrc

map <silent> \ :let @/=""<cr>:echo ""<cr>
map <silent> H :set hls!<cr>:echo ""<cr>

(type \ to clear the highlighted search... type H to disable highlighting altogether)

Useful part of my .irssi/config

keyboard = (
  { key = "home"; id = "command"; data = "window next"; },
  { key = "end"; id = "command"; data = "window prev"; },
  { key = "`"; id = "key"; data = "meta"; }
);

(use HOME to go to the next window, use END to go to the previous window... and binds ` to "meta" because it doesn't hear my alt key.)

Retrieved from "http://shii.org/knows/Screen"

This page has been accessed 2,171 times. This page was last modified on 4 April 2008, at 04:44. Content is available under Attribution 2.5 .