DirectNET

Data Center Management Solutions including UPS Systems, Data Center Cooling, KVM over IP & IP Power Strips, Server Racks and Server Rack accessories; KVM Switches and KVM Extenders; Rackmount Monitors and Rackmount Keyboards.


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
Surveys
NEWS
Current
Press
Archive
FEATURES
Editorial
Dr. Mac
Reviews
Reader Reports
RESOURCES
FAQ
Documentation
Learning Center
MAN pages
Glossary
Tutorials
Tips
Links

OUR PARTNERS

OSXFAQ Mac OS X UNIX Tip-of-the-Day   back to index

Week 106 - New in Tiger (2 January 2006)

by Adrian Mayo - Editor, OSXFAQ

Thursday - More New Commands

Tiger includes the following commands that were not in earlier versions of Mac OS X.

1) The Korn shell in /bin/ksh, useful if you ever want to run a Korn shell script (or if you prefer to use Korn as your interactive shell!)

2) zless, part of the GNU zip toolkit, displays gzip compressed files directly using the less command. It's actually a very simple wrapper script:

$ cat /usr/bin/zless
#!/bin/sh
PATH="/usr/bin:$PATH"; export PATH
LESSOPEN="|gzip -cdfq %s"; export LESSOPEN
exec less "$@"
$

3) textutil, which is a command line interface to the Cocoa text system. Some examples of using textutil are:

To convert the HTML file index.html to rich text format, written to index.rtf, type:

$ textutil -convert rtf index.html

To convert the same file to an MS Word document, written to index.doc, type:

$ textutil -convert doc index.html

The -cat option is handy to concatenate all the input files into one big output file.

4) mdfind is a command line Spotlight. It searches through meta data for attribute values, or for specific attributes with given values.

Check the man pages for textutil and mdfind for full details.

Here's a handy tip to convert postscript output to PDF using Preview.app. In this example we pipe the raw postfix man page for bash into Preview.app.

$ man -t bash | open -f -a /Applications/Preview.app

Visit the Site of the Book of the Unix Tips:


Discuss this trick in the Learning Center forum


Copyright © 2000-2010 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.