It looks like you haven't used command line parameters yet.

For a useful improvement, try replacing <archivefilename> with $1 and 
<packagename> with $2 in the script, representing the first and second 
parameters on the command line.
The call the script as follows (assuming it's named "download_archive"
download_archive "archive name" "packege name"

Then you won't have to use the vim search-and-replace for each package/archive 
combination.

Thomas Sapp wrote:
> Hello,
> My name is Tom, I am new to PLUG and am hoping to find time to start
> attending meetings.  Until then I hope to find some interesting
> discussions here on this mailing list.
> 
> I've recently been playing around with creating a working LFS system and
> have been having lots of fun at learning about all that goes in to
> putting a working Linux system together.  Now that I am almost done with
> the BLFS book, I was wondering if I might get some critique on my first,
> what I would consider, real shell script.  I wrote it while going
> through the process of downloading and compiling the various packages I
> wanted/needed on my system.  I basically downloads the needed archives,
> extracts them, runs the commands provided, and then removes the
> extracted directory and downloaded archive from the system.  I added a
> some easily replaceable placeholders that I can us the %s option in vim
> on.  So far it has worked fairly well for me.  The code for it can be
> found at http://pastebin.com/ESjVCmTF.
> 
> I am looking forward to hearing any advice regarding this and also
> participating in this mailing list in the future.
> 

Attachment: signature.asc
Description: OpenPGP digital signature

---------------------------------------------------
PLUG-discuss mailing list - [email protected]
To subscribe, unsubscribe, or to change your mail settings:
http://lists.PLUG.phoenix.az.us/mailman/listinfo/plug-discuss

Reply via email to