Create an Account
username: password:
 
  MemeStreams Logo

semi-useful aliases for UNIX shells

search

Neoteric
Picture of Neoteric
Neoteric's Pics
My Blog
My Profile
My Audience
My Sources
Send Me a Message

sponsored links

Neoteric's topics
Arts
  Music
   Blues
   Country
   Rap & Hip Hop
  TV
Business
Games
Health and Wellness
  Fitness
  Medicine
  Nutrition
Cooking
Entertaining
Holidays
Miscellaneous
  MemeStreams
Current Events
  War on Terrorism
Recreation
  Bicycling
  Camping and Hiking
Local Information
  Food
  United States
   District of Columbia
    Events in Washington D.C.
    News for Washington D.C.
   Maryland
Science
  Chemistry
  Math
  Physics
Society
  Politics and Law
   Surveillance
   Intellectual Property
Technology
  Computer Security
  Cyber-Culture
  Linux
  Software Development
  High Tech Developments

support us

Get MemeStreams Stuff!


 
semi-useful aliases for UNIX shells
Topic: Linux 1:29 pm EDT, Sep 12, 2008

A common idiom in UNIX is to create a dir and then cd into it to do something. This is is a ksh compliant function to make a dir and cd into it... note that if you are dumb and give it more than one arguement you'll probably be sad.

To use put this in your .profile or .bashrc or where ever you put your shell tweaks. I've been told that this thing is easier to do in zsh.

--snip--snip--snip--
cdmkdir () {
mkdir "$*";
cd "$*";
}
--snip--snip--snip--

--timball



 
 
Powered By Industrial Memetics
RSS2.0