Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Portable (USB) install using 3.6.7 from nethack.org?

84 views
Skip to first unread message

cookie

unread,
Jul 21, 2023, 2:14:32 PM7/21/23
to
Returning to NetHack after a while, I am trying to configure the standard 3.6.7 windows build (NetHackW.exe) to run from a root folder on a USB stick - is this still possible? Whatever I try it seems to insist on creating and using files in windoze folders (ProgramData and user profile). I just want a single user setup that I can run from a USB stick...
E.g. using "sysconf" to redirect all folders:
CONFIGDIR=d:\games\nethack\config
TROUBLEDIR=d:\games\nethack\trouble
HACKDIR=d:\games\nethack
LEVELDIR=d:\games\nethack\temp
SAVEDIR=d:\games\nethack\saves
BONESDIR=d:\games\nethack\bones
SCOREDIR=d:\games\nethack\scores
LOCKDIR=d:\games\nethack\temp
...still recreates and uses the profile .nethackrc.
Have I missed something obvious? There's nothing helpful on reddit and nethackwiki.com doesn't have anything relevant either.
Any help appreciated. Mark C

Pat Rankin

unread,
Jul 21, 2023, 6:14:07 PM7/21/23
to
On Friday, July 21, 2023 at 11:14:32 AM UTC-7, cookie wrote:
> E.g. using "sysconf" to redirect all folders:
[...]
> Any help appreciated. Mark C

I believe that the sysconf directive 'PORTABLE_DEVICE_PATHS' is
supposed to do exactly what you're asking for.

I've never tried it. I think you need to both uncomment it (remove
the leading hash) and change the value from 0 to 1.

cookie

unread,
Jul 22, 2023, 8:07:24 AM7/22/23
to
On Friday, July 21, 2023 at 11:14:07 PM UTC+1, Pat Rankin wrote:
> On Friday, July 21, 2023 at 11:14:32 AM UTC-7, cookie wrote:
> > E.g. using "sysconf" to redirect all folders:
> [...]
> > Any help appreciated. Mark C
> I believe that the sysconf directive 'PORTABLE_DEVICE_PATHS' is
> supposed to do exactly what you're asking for.

Thanks very much Pat! This is not in the sysconf.template but I do remember reading about this - I found it again buried around line 5624 in the guidebook.txt.

Now to try not to die too often as I remember how to play...

B. R. 'BeAr' Ederson

unread,
Jul 22, 2023, 1:10:55 PM7/22/23
to
On Fri, 21 Jul 2023 11:14:29 -0700 (PDT), cookie wrote:

> I just want a single user setup that I can run from a USB stick...
[...]
> HACKDIR=d:\games\nethack
> LEVELDIR=d:\games\nethack\temp
> BONESDIR=d:\games\nethack\bones

In addition to the sysconfig "PORTABLE_DEVICE_PATHS = 1" setting Pat
already mentioned, you probably should consider using relative path
entries to get a _real_ portable setup, like:

HACKDIR=.
LEVELDIR=.\temp
BONESDIR=.\bones

Please note, that path settings from .nethackrc (user settings) override
these from sysconfig (system settings). Best to check that every path
points to the intended location with:

NetHackW.exe --showpaths

Some information on Windows (portable) settings can be found here:
https://www.nethack.org/v367/bugmore/WinFilePaths.txt

BeAr
--
===========================================================================
= What do you mean with: "Perfection is always an illusion"? =
===============================================================--(Oops!)===
0 new messages