<html><head><style type='text/css'>p { margin: 0; }</style></head><body><div style='font-family: arial,helvetica,sans-serif; font-size: 12pt; color: #000000'><font face="arial, helvetica, sans-serif"><span style="font-size: 12pt;">I've always used psg too. Also md for mkdir but that's pretty boring.</span></font><div style="color: rgb(0, 0, 0); font-family: arial, helvetica, sans-serif; font-size: 12pt;"><br></div><div style="color: rgb(0, 0, 0); font-family: arial, helvetica, sans-serif; font-size: 12pt;">Actually, taking a peek at my .bashrc, it looks like a while back I switched psg from an alias to a function:</div><div style="color: rgb(0, 0, 0); font-family: arial, helvetica, sans-serif; font-size: 12pt;"><br></div><div style="color: rgb(0, 0, 0); font-family: arial, helvetica, sans-serif; font-size: 12pt;"><div style="font-size: 12pt;">psg ()</div><div style="font-size: 12pt;">{</div><div style="font-size: 12pt;"> ps -ef | egrep ^UID\|\[${1:0:1}\]${1:1}</div><div style="font-size: 12pt;">}</div><div><br></div><div>This version gives me the header line and avoids the grep in the output.</div></div><div style="color: rgb(0, 0, 0); font-family: arial, helvetica, sans-serif; font-size: 12pt;"><br></div><div style="font-size: 12pt; font-family: arial, helvetica, sans-serif;">Since more often than not I seem to want to cd to the directory I just made, I also use: </div><div style="color: rgb(0, 0, 0); font-family: arial, helvetica, sans-serif; font-size: 12pt;"><br></div><div style="color: rgb(0, 0, 0); font-family: arial, helvetica, sans-serif; font-size: 12pt;">mdcd()</div><div style="color: rgb(0, 0, 0); font-family: arial, helvetica, sans-serif; font-size: 12pt;">{</div><div style="color: rgb(0, 0, 0); font-family: arial, helvetica, sans-serif; font-size: 12pt;"> mkdir "$@"</div><div style="color: rgb(0, 0, 0); font-family: arial, helvetica, sans-serif; font-size: 12pt;"> cd "$_"</div><div style="color: rgb(0, 0, 0); font-family: arial, helvetica, sans-serif; font-size: 12pt;">}</div><div style="color: rgb(0, 0, 0); font-family: arial, helvetica, sans-serif; font-size: 12pt;"><br></div><div style="color: rgb(0, 0, 0); font-family: arial, helvetica, sans-serif; font-size: 12pt;"></div><div style="color: rgb(0, 0, 0); font-family: arial, helvetica, sans-serif; font-size: 12pt;">I think it was ksh that had a -c option on type that read though the symbolic links to tell you where the real file was. The c was for canonical I believe. Anyway bash doesn't have that option so I've been using this one for many years too, ever since I switched to bash:</div><div style="color: rgb(0, 0, 0); font-family: arial, helvetica, sans-serif; font-size: 12pt;"><br></div><div><div><font face="arial, helvetica, sans-serif">type()</font></div><div><font face="arial, helvetica, sans-serif">{</font></div><div><font face="arial, helvetica, sans-serif"> if [ "$1" = "-c" ]</font></div><div><font face="arial, helvetica, sans-serif"> then</font></div><div><font face="arial, helvetica, sans-serif"> shift;</font></div><div><font face="arial, helvetica, sans-serif"> for f in "$@"</font></div><div><font face="arial, helvetica, sans-serif"> do</font></div><div><font face="arial, helvetica, sans-serif"> ff=$(builtin type -p "$f")</font></div><div><font face="arial, helvetica, sans-serif"> readlink -f "$ff"</font></div><div><font face="arial, helvetica, sans-serif"> done</font></div><div><font face="arial, helvetica, sans-serif"> else</font></div><div><font face="arial, helvetica, sans-serif"> builtin type $typeopts "$@"</font></div><div><font face="arial, helvetica, sans-serif"> fi</font></div><div><font face="arial, helvetica, sans-serif">}</font></div><div><font face="arial, helvetica, sans-serif"><br></font></div><div><font face="arial, helvetica, sans-serif">I know you asked for aliases, but most of mine grew into functions it seems. I do also alias vi to vim and more to less, but mostly because I couldn't get out of old habits.</font></div><div><br></div><div><font face="arial, helvetica, sans-serif">Also this one </font><span style="font-family: arial, helvetica, sans-serif;">is handy to replace scp for a large file</span><span style="font-family: arial, helvetica, sans-serif;">:</span></div><div><font face="arial, helvetica, sans-serif">alias rscp='rsync --partial --progress --stats --inplace'</font></div><div><br></div><div><span style="font-family: arial, helvetica, sans-serif;">This one is handy if you're having trouble connecting with ssh:</span></div><div><div><font face="arial, helvetica, sans-serif">alias sshv='ssh -vvv -o LogLevel=DEBUG3'</font></div><div style="font-family: arial, helvetica, sans-serif;"><br></div></div><div><span style="font-family: arial, helvetica, sans-serif;">Scott</span></div><div></div><div><br></div><hr id="zwchr" style="color: rgb(0, 0, 0); font-family: arial, helvetica, sans-serif; font-size: 12pt;"><div style="color: rgb(0, 0, 0); font-family: Helvetica, Arial, sans-serif; font-size: 12pt; font-weight: normal; font-style: normal; text-decoration: none;"><b>From: </b>"JD" <jdp@algoloma.com><br><b>To: </b>"Atlanta Linux Enthusiasts" <ale@ale.org><br><b>Sent: </b>Saturday, January 10, 2015 10:40:56 AM<br><b>Subject: </b>[ale] Favorite Aliases?<br><br>It has been awfully quiet here.<br><br>What are your 3 favorite aliases?<br><br>Let's skip the ls/du/df ones, ok?<br><br># ps with a grep<br>alias psg='ps -eaf | grep $*'<br><br><br><br>Oh and for programs that I constantly misspell, I'll create multiple aliases<br>with the misspellings just to save time.<br><br><br>_______________________________________________<br>Ale mailing list<br>Ale@ale.org<br>http://mail.ale.org/mailman/listinfo/ale<br>See JOBS, ANNOUNCE and SCHOOLS lists at<br>http://mail.ale.org/mailman/listinfo<br></div><br></div></div></body></html>