This is for people with some knowledge of UH Unix. If you don't even know what UH unix is, then you probably don't need tips and tricks to it huh? Just a warning, please try not to mess up your account too much with these, especially the modifying your .cshrc file =)
Rather than typing uhunix2.its.hawaii.edu, you can type in mud.hawaii.edu. mud apparently
is some shortcut DNS entry for uhunix2.
After doing a pico on a file, ctrl K erases a whole line.
ctrl V is the equivalent of page down, and ctrl Y is like page up.
ctrl K erases a line of text, and ctrl U brings it back.
find . -name filename -print (Example: find . -name index.html -print)
You can find some file, like in the example, you can find occurances of the file "/uhraps/index.html". You need the exact file name though.
find . -name "*file" -print (Example: find . -name "*java" -print)
This is for finding files that end with something by putting the star (*) in front. In the example, I found all files ending in java. To find an exact file, you don't need the " " signs, but to find something like all files ending in java, you need to have the " " signs
you can also do something like:
find . -name "java*" -print
that will find all files that start with "java" by putting it the star at the end.
Hitting ctrl C anywhere will cancel and stop a running program.
Create a .forward file
(Do this by typing pico .forward in the command line.) In that .forward file, put one email address. Now, anytime that anyone sends email to that address, it will go instead to the one you specified. You can also specify many email addresses, seperated by commas . . . but why would you want others to read your UH email?
In pine, go to Setup (s), then Config (c), then you can change the name on outgoing
email by erasing your middle name that most people don't want, or make up a whole fake
name (but people can still tell it's you by your email addy). Then press (e) to exit.
To change your password, go to the same Setup (s), then Newpassword (n).
To avoid a ^H in the command line when you hit backspace, there are a few things
you can do. Either type the delete key (instead of backspace), type ctrl
backspace, use tcsh (see below), or download my backspace program (all the way down).
Normally, ls, or ls -l (those are L's, not one's) will give you a listing of your files and folders. ls -R will give you a listing of all files, folders, and contents of all folders. (Hope your terminal can scroll back)
Will let you know how much space you have on your account. (You're allowed 20 megs, or about 20,000 kilobytes)
You can also use this following command below. This takes longer, but it will give you more information:
quota -v username (Example: quota -v dninomiy)
This will refresh your account by reloading your main system file, .cshrc.
This lets you have a more enhanced csh (C-Shell). It allows the equivalent of DOSKey (can hit the up arrow to see previous commands), makes a clean backspace on whatever terminal you're at. When you exit, you'll have to exit out of both the tcsh and your regular csh account though. This is good for programming since having a DOSKey type function would be useful, and being able to erase ok =). If you try putting tcsh in your .cshrc file, it will be kinda messed up though.
chmod -R number directory (Example: chmod -R 755 public_html)
If you don't know what chmod is, then you probably don't need to use this one . . . Basically, the -R is the sign for recursive, so if you executed my example of chmod -R 755 public_html, then everything in the directory of public_html will be chmod at 755, and everything in all the subdirectories will also be chmod at 755.
last username (Example: last dninomiy)
This will let you see when this person logged on recently on that unix (uhunix1, uhunix2, etc.)
Like if you wanna see when I logged on recently, try last dninomiy. If the last command goes too fast for you, try "last | grep username" to make them go slower.
finger name | grep Lastname (Example: finger david | grep Ninomiya)
You can find someone's UH username. Normally, with the finger command, you can only search for one name, like either David, or Ninomiya. With this, you can do a search on 2 parts of their name. Note: the 1st name you put in (david) can be lower case, but the 2nd part of the name (Ninomiya) must be capitalized.
(You can switch this, like: finger ninomiya | grep David)
man command (Example: man pico)
If you want help with something, type man, then the thing you want help with. It's sort of like a help command, except it's for manual, so like "man pine", or "man shell", depending on what you want help with.
echo what message you want to say | write username (Example: echo hi david | write dninomiy)
(will say "hi david" to me while I'm on unix)
alias fakedns 'exec login -h "a.fake.addy.com"'
Changes what server you appear to be on. (Good for confusing people on pal). Since this is a long code to run in the command line, I suggest you put it in your .cshrc file, so you can execute this easier. However, you can just type in the command line, and it will work:
exec login -h "fake.server.com"
For putting it into your .cshrc file, you can try stuff like this:
alias dnd 'exec login -h "do.not.disturb"'
alias gov 'exec login -h "secret.gov.mil"'
This will log you directly into pine (your inbox) rather than you having to actually type in pine when you start, and typing "i" to get into your inbox. Note, you can also put this code into your .login file.
alias c pine -I c
If you put this in your .cshrc file, everytime you hit "c", it will lead you straight to composing an email in pine.
Make an ascii picture, or notes to self, or some famous phrase, and call it something like introfile. "cat introfile" will load that file everytime you log in. This could be used for your own amusement, to remind you of events, etc. Note, you do not need to name it introfile, I just made that up.
(on a side note, putting something like cat exitfile in the bottom of your .logout
file after creating a file called "exitfile" will make that pic/note/quote,
etc. appear as you logout)
stty erase ^H
(Add this to erase those stupid ^H when you try to hit backspace. If you switch between "good" terminals, and telnet like bad terminals a lot, check out my backspace program at the bottom of this page. Adding this code will make your telnet backspaces clean, but if you go to some advanced terminal like QVT, backspaces will become ugly, like ^?. If you switch a lot, or want an option, download my Backspace Program, listed below)
set prompt="your new command?: "
Changes the prompt from something like uhunix1:home/17/username% to whatever you want it to be. I just chose "your new command?:" as an example. Personally, I use "Orders Sir?: " (after what the marines say in the game Starcraft). Other friends use "Yes Master . . . ", "what is you desire, m'lady", etc.
Follow these easy steps to copy, then install these programs.
Pal by Chris Komatsu
cp ~dninomiy/pal pal
(Copies over a version of pal. It's a cool stalker program.)
chmod 755 pal
(To make it executable)
(Typing ./ runs programs in unix.)
Backspace Program by David Ninomiya
cp ~dninomiy/backspace backspace (Copies over a version of my backspace program.)
chmod 755 backspace
(To make it executable)
To modify the prompt after installation, do a pico bksp-prompt (you'll see what I mean).