5.0.3
Site Update 02/16/07  

Game Track finally has defined levels of priority. Before it was only an idea of what each level meant. I also added new colors to make the levels stand apart. Plus the new, vibrant colors match v5's design better.

Journal Updates
11/06: Screen and Vim Setup
10/21: Time for a Career Change
07/09: From the Ashes
04/07: FiOS Today
03/30: Spring Break
03/28: Bluetooth Headsets
03/27: Secrets
Xbox Live
Gaming Updates
08/23/09: Jeanne d'Arc
08/23/09: MLB '09: The Show
08/18/09: Bubble Bobble
08/18/09: Need for Speed: Carbon
08/18/09: Little Big Planet
08/18/09: Eternal Sonara
08/18/09: Valkyria Chronicles
November 06, 2009 @ 11:16
Screen and Vim Setup

I love screen. I love vim. One problem I have is that I can't seem to remember which screen session is editing which file. I decided to spend some time and get this fixed, once and for all.

My screen now has a persistent line showing the window setup. Obviously it won't be perfect for the number of windows I run at home, but it's working nicely at work.

The screen line is the last line in my terminal and looks like:

[ hostname ][ 0 mysql 1- tcsh (2*tcsh) ][11:09]

(I'm not spending time showing all the colors here. You could adjust them if you like.)

If you want to use this, put this line in your .screenrc:

hardstatus alwayslastline '%{= kG}[ %{G}%H %{G}]%{g}[%= %{=kw}%?%-Lw%?%{r}(%{W}%n*%f%t%?(%u)%?%{r})%{w}%?%+Lw%?%?%= %{g}]%{G}[%{W}%c%{G}]'

Now, for the vim setup. I've always noticed that my screen titles are useless. They all say 'tcsh' unless I have pre-titled them (like the mysql above). What if vim could change the title for me? As it turns out, it can.

I open a new window and a new file, test.txt. Now my bottom of my terminal shows:
"test.txt" [New File] 0,0-1 All
[ hostname ][ 0 mysql 1 tcsh 2- tcsh (3*vim:test.txt) ][11:14]

Closing the vim session resets the title back to tcsh as well.

If you want this, add the following to your .vimrc:

let &titlestring = "vim:" . expand("%:t")
let &titleold = "tcsh"
if &term == "screen"
set t_ts=^[k
set t_fs=^[\
endif
if &term == "screen" || &term == "xterm"
set title
endif

(Those are escapes ( ^[ ) in the set. Control-v + escape in vim ^^)

If you like this, let me know. Thanks.


blog.cgi (v1.3) 06/15 16:59

Now Playing
Xbox 360 Mass Effect The Citadel 3:45
 
PlayStation 2 Shin Megami Tensei: Persona 3: FES October 7 74:50
Floor 164 reached
PlayStation 3 MLB '09: The Show Career Mode  
Playing AA ball. I need to stop playing until early morning.

game.cgi (v1.3) 01/21 16:22
This home page is solely designed and maintained by the resident dragon, Firemyst. The page is about his life, hobbies, and interests. Firemyst has had a homepage since May 1994. The first location for this page was at Xmission in Salt Lake City, Utah. This is the fifth redesign for Firemyst's Lair. Currently dragon.rpgamer.com resides on a private server, a macmini, located near Seattle, WA, USA.

Version 5.0 of Firemyst's Lair launched on October 24, 2006.

FreeBSD   Perl   mySQL   Roxen   Valid XHTML 1.0!   Valid CSS!