Jump to content

Screen: Difference between revisions

1,225 bytes added ,  3 November 2012
 
(5 intermediate revisions by 3 users not shown)
Line 1: Line 1:
== Basics ==
== Basics ==
'''Screen''' usually does not exist. This <s>is the committee's</s>was a former committee's general position on screen due to the disastrous and/or hilarious situations which often result from new members' attempts to get it working. However, for the purpose of this tutorial, screen '''does''' exist, and this is how you use it. (Blame coconut for this defiance.)
'''Screen''' usually does not exist; this <s>is the committee's</s> was a former committee's general position on screen due to the disastrous and/or hilarious situations which often result from new members' attempts to get it working. However, for the purpose of this tutorial, screen '''does''' exist, and this is how you use it. (Blame coconut for this defiance.)


=== Omg, what's screen? ===
=== Omg, what's screen? ===
Line 89: Line 89:


followed by the id listed above of the screen you want to reattach to.
followed by the id listed above of the screen you want to reattach to.
=== Moving windows ===
If are in a window, but want it to move it to another, just type these commands while attached to screen and in that window, and replace '''x''' with the destination you want:
Ctrl + a
:
number x
For example, if you are in window number 2, press '''Ctrl+a''', then type the colon symbol (''':'''), then '''number 4''', to move that window to window 4.


=== Start and stop signals ===
=== Start and stop signals ===
Line 145: Line 154:
  hardstatus string '%{= kg}[ %{G}%H %{g}][%= %{= kw}%?%-Lw%?%{=b kR}(%{W}%n*%f %t%?(%u)%?%{=b kR})%{= kw}%?%+Lw%? %?%= %{g}][%{Y}%l%{g}]%{=b C}[ %d %M %c ]%{W}'
  hardstatus string '%{= kg}[ %{G}%H %{g}][%= %{= kw}%?%-Lw%?%{=b kR}(%{W}%n*%f %t%?(%u)%?%{=b kR})%{= kw}%?%+Lw%? %?%= %{g}][%{Y}%l%{g}]%{=b C}[ %d %M %c ]%{W}'
  deflogin off
  deflogin off
startup_message off
  screen -t irc 1 irssi
  screen -t irc 1 irssi
  screen -t Email/slrn 2 mutt -Z
  screen -t Email/slrn 2 mutt -Z
Line 160: Line 170:


This sets windows logged out by default, which means that you won't have to "mesg n" windows to not receive heys
This sets windows logged out by default, which means that you won't have to "mesg n" windows to not receive heys
startup_message off
This turns the startup message thats displayed when you start a new screen session off.


  screen -t heys -L -l  3
  screen -t heys -L -l  3
Line 170: Line 184:


[[Image:screenrc.jpg]]
[[Image:screenrc.jpg]]
=== Reattaching Screen Automatically ===
So, you've made your screen, configured it, and you happily type screen -dr '''every time''' you login to RedBrick. But wouldn't it be nice if whenever you login your screen would reattach '''itself'''??? It can be done :D
Simply use your favorite text editor to edit your ~/.zlogin if you're using zsh (if you haven't changed your login shell, this is the one you're using) or ~/.bash_login if you're using bash and put the following in it
screen -dr
That should do the job. It'll try to reattach a screen whenever you login on any redbrick server
* Please note, if this in fact, does not work, you can edit it out by using winSCP and editing the file using it.


== Useful links ==
== Useful links ==
145

edits