Use tr to transform a text string

April 20th, 2004

Problem: In a shell script to back up a directory, you want to save the directory as a tar file whose name includes the full original path (just in case you have multiple directories, in separate locations, with the same name). So you want to save a directory with the path /dev/fs/D/mydir to a tar file called BACKUP_.dev.fs.D.mydir. Solution: Use tr to transform the path string. For example, the path to the directory you are backing up (/dev/fs/D/mydir) is stored in the variable $DIRECTORY. Use the following commands to create a variable called $NAME containing BACKUP_.dev.fs.D.mydir. NAME = `echo $DIRECTORY | tr '/' '.'` NAME = BACKUP_`echo $NAME | tr '\' '.'` Note: don't mix up the backticks and the single quotes.

Leave a comment

 

FrameMaker history

April 19th, 2004

I've been digging around trying to find out some more about the history of FrameMaker and I came across the following email in the Framers-Digest of Tuesday, May 13 1997 (Volume 02 : Number 280):
Date: Mon, 12 May 1997 21:15:05 -0400
From: John Albino
Subject: Re: FrameMaker early history

At 02:06 AM 5/12/97 GMT, you wrote:

>One engineer did something about it; on his own, David Murray wrote
>Framemaker. He met a marketer who saw the next Interleaf in it, Steve
>whose last name escapes me now, but who was the first president of
>Frame)

Actually, Charles Corfield was the "engineer" who wrote the first version of FrameMaker -- he needed something better than other available tools for doing his dissertation, and that was the gestation of Frame. He got together with David Murray (who actually was a music major) and Steve Kirsch (who founded Mouse Systems and had a few million hanging around after cashing out of Mouse) and the company was founded, along with (Ronnie?) Blakeley who had been with Steve at Mouse systems.

The market was so hungry for an *affordable* alternative to Interleaf that Frame was able to sell lots of licenses at approx. $1,500 each for over a year for the pre-1.0 beta version, with the promise of a free upgrade to the shipping production version. (Interleaf was selling turnkey systems for around $30K at the time, and wanted the same bucks for software only.)

Frame got *real* big with FedGovCo, which appreciated it as an unbundled software package (as opposed to Interleaf, which wanted to sell only turnkey hardware/software combinations at the time), and also because Interleaf had PO'ed Sun by using a deal Interleaf had with Sun for hardware to undercut Sun's own prices for the same hardware. Sun jumped on the chance to use FrameMaker as a "Friend of Sun" and gave Frame lots of marketing support.
Frame founder Charles Corfield is now a director of, and investor in, several Silicon Valley startups. Read a profile of Steve Kirsch at: www.spectrum.ieee.org/publicfeature/aug00/prof.html Seybold Report from 1996: Adobe acquires Frame, plans full takeover www.seyboldreports.com/SRPS/free/0ps24/P2421023.htm

Potentially similar posts

Leave a comment



Stop using tables for layout

April 18th, 2004

I've always thought that using tables for laying out a Web page was an irritating and ugly workaround. CSS offers a more palatable solution. There are still problems, however, but these sites show some of the possibilities: www.bluerobot.com/web/layouts – The Layout Resevoir glish.com/css – Look Ma, No Tables

Leave a comment



Using rcp and cron to perform a scheduled network backup

April 14th, 2004

I recently set up a cron job on my PC to backup files from the PC to a network server every night. The technique uses SFU on the PC, rcp to copy the files to the network and cron to perform the backup at 3.15 every morning. For a full description, see: www.itauthor.com/unix_linux_shell/shell-backup-script.html

Potentially similar posts

Leave a comment



Grepping ls output

April 14th, 2004

grep is a useful tool for modifying the output from ls (the UNIX directory listing command).

For example, if you want to list only the files beginning with a full stop ("."), you can use the command:
ls -a | grep '^\.'

Note: if you're going to be using \ or * you need to enclose the expression that you pass to grep in single quotes.

I frequently want to list just the directories within the current directory. This is especially useful in a directory with lots of files. To do this I use the command:
ls -l | grep ^d

Which produces something like:
drwxr-sr-x   2 me    mygroup   512 Mar  1  2002 News
drwx--S---   2 me    mygroup   512 Dec  8 12:42 Trash
drwxr-sr-x   3 me    mygroup   512 Jan  9 15:59 cvs
drwxrwsrwx   7 me    mygroup   512 Apr 14 00:28 documents-archive
drwx------   2 me    mygroup   512 Aug  4  2003 downloaded-files
drwx------   2 me    mygroup   512 Sep 18  2002 mail
drwxr-sr-x   3 me    mygroup   512 Feb 11 23:03 perlprogs
drwxrwsrwx   2 me    mygroup   512 Apr 13 23:44 temp
drwx------   2 me    mygroup   512 Aug 28  2003 upload-from-here

If you're only interested in the directory names use:
ls -l | grep ^d | awk '{print $9}'

Which prints only column 9, giving you:
News
Trash
cvs
documents-archive
downloaded-files
mail
perlprogs
temp
upload-from-here
Read the rest of this entry »

Leave a comment



^ back to top ^

Page 87 of 98« FirstNewer102030858687888990OlderLast »