Script to parse a Quote file??

Script to parse a Quote file??

Post by Randy Alexand » Wed, 03 Feb 1993 19:17:47

I.m looking for a shell script to display lines from a file
of quotes motd style. It needs to be able to handle multiple lines
and be able to use quotes of diferent size. It may look for a separator
character between quotes.. Any help?




1. quoting quotes withion a (bourne shell) script line

Hopefully an easy one but I'm tearing my hair out.

Keeping a long story short, I have a NetAPP filer with (lets say) root
access of

username : root
password : nobby'   (the end ' is supposed to be there).

Our backup software using NDMP has thism information in its

Meanwhile I need to move data from the filer above to anothjer, for
which I would enter - on a command line from the second filer -

ndmpcopy -sa root:"nobby'" filer1:/vol/vol0/data/fred

where the double quotes indicate that the strting within is the

I can only run one such line at a time from the actual command line
and the filer permits only one login at a time.

However I can rsh commands to the filer - but my trouble here is
simply how to encompass that   root:"nobby'"   bit in a (bourne) shell
script such that the command issues the password as it should be ie
nobby'  but the shell script doesn't get confused over either the
double quotes or the single quote.

I can't change the password to something simopler #cos that will break
the backups!!

How can I acheive what I need in the script?

ie how can I script

rsh ndmpcopy -sa root:"nobby'" filer1:/vol/vol0/data/fred

so that it runs like it would on the second filer and doesn't get
confused over the various quotes


2. root pw trouble with Linux 2.0.34

3. Shell Scripts read and parse lines from a file

4. OpenBoot oem-logo parameter

5. HELP - parsing text file as input to script - HELP

6. cheap lab time

7. Shell Script Parsing an XML File on Sun OS 5.5.1

8. TB Montego

9. INI files: is there a ksh shell script to parse them (like iniconf)?

10. Script to parse through files in Directory

11. script for parsing files for #if and #ifdef's

12. Shell script to parse a file

13. scripting newbie parsing file