Re: 8.0 Beta 1 // Environment Vars // .pgpass

From: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
To: Andrew Dunstan <andrew(at)dunslane(dot)net>
Cc: Joerg Hessdoerfer <Joerg(dot)Hessdoerfer(at)sea-gmbh(dot)com>, pgsql-hackers-win32(at)postgresql(dot)org, PostgreSQL-patches <pgsql-patches(at)postgresql(dot)org>
Subject: Re: 8.0 Beta 1 // Environment Vars // .pgpass
Date: 2004-08-18 02:58:50
Message-ID: 200408180258.i7I2woh17868@candle.pha.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers-win32 pgsql-patches


I have applied the attached patch which adds get_home_path() which uses
USERPROFILE on Win32 and HOME on Unix.

This should fix the reported problem.

---------------------------------------------------------------------------

Andrew Dunstan wrote:
>
>
> Joerg Hessdoerfer wrote:
>
> >On Thursday 12 August 2004 06:25, Tom Lane wrote:
> >
> >
> >>"efesar (the kay)" <efesar(at)unm(dot)edu> writes:
> >>
> >>
> >>>The 8.0 version does not acknowledge env vars like PGPASSWORD and seems
> >>>to ignore the contents of the .pgpass file.
> >>>
> >>>
> >>Hmmm. Those are probably the same problem, since finding .pgpass
> >>depends on expanding the $HOME env var. But I have no idea why
> >>env vars aren't working for you ...
> >>
> >>
> >Yep. AFAIK, $HOME doesn't always exist in WIN32, but $HOMEDRIVE and $HOMEPATH
> >(or %HOMEPATH% and %HOMEDRIVE% ;-) do. Perhaps PG needs to do some munging to
> >build the home path from those two?
> >
> >
> >
> >
>
> On my XP-Pro machine the appropriate setting appears to be %USERPROFILE%
> - %HOMEPATH% is just "\"
>
> See here for a complete list of available environment vars:
>
> http://www.winnetmag.com/Article/ArticleID/23873/23873.html
>
> cheers
>
> andrew
>
> ---------------------------(end of broadcast)---------------------------
> TIP 2: you can get off all lists at once with the unregister command
> (send "unregister YourEmailAddressHere" to majordomo(at)postgresql(dot)org)
>

--
Bruce Momjian | http://candle.pha.pa.us
pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 359-1001
+ If your life is a hard drive, | 13 Roberts Road
+ Christ can be your backup. | Newtown Square, Pennsylvania 19073

Attachment Content-Type Size
unknown_filename text/plain 6.8 KB

In response to

Browse pgsql-hackers-win32 by date

  From Date Subject
Next Message Bruce Momjian 2004-08-18 03:27:01 Re: [PATCHES] Win32 Event log
Previous Message Christopher Kings-Lynne 2004-08-18 01:33:53 Re: tablespace and sequences?

Browse pgsql-patches by date

  From Date Subject
Next Message Bruce Momjian 2004-08-18 03:00:01 Re: to_timestamp overloaded to convert from Unix epoch
Previous Message Andrew Dunstan 2004-08-18 01:44:44 Re: Allow psql to work against non-tablespace servers (e.g.