Laramie/doco/cygwin

From ThinkPrank Wiki
Revision as of 13:27, 19 November 2009 by Admin (Talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

rxvt

In Windows, I create a shortcut that looks something like this:

 C:\bin\cygwin\bin\rxvt.exe -bg black -fg white -geometry 130X50+0+0 -fn "Andale Mono-20" -e /usr/bin/bash --login -i

Where Andale Mono is a font, available from Microsoft, which can be found from this page: http://en.wikipedia.org/wiki/Andale_Mono

Then on the server I set up my bash /etc/profile like this:

alias dir='/bin/ls -la $*'
alias vimail='vi /etc/mail/domainaliases;newaliases'
export PS1='\[\033]0;\w\007
\033[32m\]b-rant \u@\h \[\033[33m\w\033[0m\]
$ '

Another way to do this, and also how I set the scroll buffer size, is this:

 If you've installed the rxvt package, you can run it from Windows without having a full X-server running, as long as you don't have a DISPLAY variable set in your environment.

 Suggested procedure:

   1. Create an ~/.Xresources file like this:

                  ! rxvt.font:          -*-lucidatypewriter-medium-*-*-*-14-*-*-*-*-*-*-*
                  ! or...
                  rxvt.font:            Lucida Console-14
                  rxvt.boldFont:        Lucida Console-14
                  rxvt.scrollBar:       True
                  rxvt.visualBell:      True
                  rxvt.loginShell:      True
                  rxvt.background:      Black
                  rxvt.foreground:      White
                  rxvt.saveLines:       3000
                  rxvt.cursorColor:     Green
                  rxvt.scrollBar_right: True
                  

   2. create a shell script like this one, so that you can pop up a new window whenever you want from within an existing shell:

                  # ~/bin/win
                  unset DISPLAY
                  rxvt -e bash -login &
                  

   3. create a DOS batch file like this one, so you can likewise create a new window by clicking an icon from Windows:

                  @echo off
                  REM place in C:\cygwin\rxvt.bat and put
                  REM a shortcut on the desktop :-)
                  c:\cygwin\bin\rxvt -e /bin/bash -login
                  

from: http://www.zieg.com/faqs/cygwin/

ssh

From each client, I run the openssh command:

 sshkeygen

without a passphrase, then copy the public key to the server using scp and a password. Then I append it:

cd .ssh cat publickey >> authorized_keys

then I vi the file to put in a blank line, and make sure that it is rw-r--r--.

Personal tools