|


| NAVIGATION |
|
Home |
|
Store |
|
|
| INSIDE MAC |
|
Television Shows |
|
Broadcast Shows |
|
Daily News Shows |
|
Special Shows |
|
|
| EVENTS |
|
|
|
|
|
|
|
|
| DAILY TIPS |
|
Design |
|
Mac OS X |
|
Mac OS X UNIX |
|
|
| COMMUNITY |
|
Forums |
|
Surveys |
|
|
| NEWS |
|
Current |
|
Press |
|
Archive |
|
|
| FEATURES |
|
Editorial |
|
Dr. Mac |
|
Reviews |
|
Reader Reports |
|
|
| RESOURCES |
|
FAQ |
|
Documentation |
|
Learning Center |
|
MAN pages |
|
Glossary |
|
Tutorials |
|
Tips |
|
Links |
|
|
|

|
|
|
OSXFAQ Daily Unix Tricks

Week 71 - Bash Shell Customisation (2 February 2004)
by
Adrian Mayo - Senior Editor for Mac OS X Unix
Monday - Shell Options
Use command 'shopt' to set shell options.
To set:
$ shopt -s <option>
To unset:
$ shopt -u <option>
To list:
$ shopt
Some useful options are illustrated below.
(1) Use 'cdspell' to correct minor typo's in filenames given to 'cd':
$ cd Dekstop
bash: cd: Dekstop: No such file or directory
Now set shell option 'cdspell':
$ shopt -s cdspell
$ cd Dekstop
Desktop
(2) Create short aliases for long directory names:
$ shopt -s cdable_vars
$ cal="/Users/saruman/Sites/calendar"
$ cd cal
/Users/saruman/Sites/calendar
Note: don't use the '~' alias in 'cdable' variables.
If you want to learn more about Mac OS X Unix visit the Learning Center
click.
- For beginners: the Mac OS X Unix Tutorial
- For detailed information on specific topics: Mac OS X Advanced Unix
- For answers to common problems: Mac OS X How To
|





|
 |
|
 |
Copyright © 2000-2008 Inside Mac Media, Inc. All rights reserved. |
Apple assumes no responsibility with regard to the selection, performance, or use of the products or services. All understandings, agreements, or warranties, if any, take place directly between the vendors and prospective users. |
| Apple, the Apple logo, Mac, PowerMac G4, PowerMac G5, Xserve, Xserve RAID, PowerBook, iBook, Airport, AirPort Extreme, iMac, eMac, iLife, iMovie, iCal, iPhoto, iTunes, QuickTime, FireWire, iPod, iSight, AppleWorks, Macintosh, Jaguar, Panther, Mac OS, Mac OS X and Mac OS X Server are trademarks of Apple Computer, Inc. |
|