View Single Post
  #6   (View Single Post)  
Old 4th June 2008
TerryP's Avatar
TerryP TerryP is offline
Arp Constable
 
Join Date: May 2008
Location: USofA
Posts: 1,547
Default

You don't need to set the release and architecture if you apply a little creative scripting:

Code:
PKG_PATH="ftp://ftp.usa.openbsd.org/pub/OpenBSD/`uname -r`/packages/`uname -m`/:ftp://ftp.openbsd.org//pub/OpenBSD/`uname -r`/packages/`uname -m`/"; export PKG_PATH
the above sets my PKG_PATH to the two mirrors (see the man page for pkg_add), and it uses the current installations release level and arch ;-)

i.e.

Code:
$ echo "ftp://ftp.usa.openbsd.org/pub/OpenBSD/`uname -r`/packages/`uname -m`/"

ftp://ftp.usa.openbsd.org/pub/OpenBSD/4.3/packages/i386/
__________________
My Journal

Thou shalt check the array bounds of all strings (indeed, all arrays), for surely where thou typest ``foo'' someone someday shall type ``supercalifragilisticexpialidocious''.
Reply With Quote