Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 01 Feb 2002 15:56:49 -0600
From:      Bob <BobGiesen@earthlink.net>
To:        Joe & Fhe Barbish <barbish@a1poweruser.com>
Cc:        Dan Nelson <dnelson@allantgroup.com>, FBSD <freebsd-questions@FreeBSD.ORG>
Subject:   Re: Change default ftp site for pkg_add
Message-ID:  <3C5B0F21.2C2AE5C6@earthlink.net>
References:  <LPBBIGIAAKKEOEJOLEGOMEDNCGAA.barbish@a1poweruser.com>

next in thread | previous in thread | raw e-mail | index | archive | help
Joe & Fhe Barbish wrote:
> 
> I see the man page on my pc is really different than
> what is on the FBSD.org web site. So the web site man
> page talks about the environment variable PACKAGEROOT
> but as usual it does not say anything about where or
> how to set this environment variable.
> 
> How do I set this environment variable?

   This is just a general note FYI; I'm not familiar with the workings
of pkg_add, whatsoever.
   Strictly speaking, an "environment" variable is one that exists in
the evironment in which the program is run -- that is, the shell from
which you run it.  So, you could set an environment variable any way
you like, so long as it is in effect when you run the program.
   So, you could set it i your .profile (or .login ...), .shrc (...)
or any other script that gets read into ytour shell (via the dot (".")
operator) -- or you could simply set the variable -- and export it --
from the command line before running the program.  In ksh, e.g.:
PACKAGEROOT="ftp://ftp3.FreeBSD.org"; export PACKAGEROOT
   If you have a fave site, you might want to put it in your profile. 
Otherwise, you can just do it at a commandline -- or even create a
script with a few options.  (But you have to "dot" the script into
your environment if you set the variable(s) via script.)
HTH
-Bob

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?3C5B0F21.2C2AE5C6>