Alex Harsanyi
unread,Jul 25, 2020, 5:02:09 AM7/25/20Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to Racket Users
If a Racket package uses `get-preference` and `(find-system-path 'pref-dir)`
to store some data, is there a way for an application using that package to
override the default preferences file used and the preferences directory
returned by `(find-system-path 'pref-dir)`?
The reason I ask this question is that my map-widget package uses
"(find-system-path 'pref-dir)" to determine the location used to store the
cache for the downloaded map tiles and also uses `get-preference` to retrieve
some parameters regarding map rendering.
This approach works fine when a user installs the package and uses it directly
within Racket, however, when the package is used as part of an application
(and especially when building a standalone distribution of the application), I
would like to be able to override what `(find-system-path 'pref-dir)` returns,
as by default it points to a "racket" path (e.g. %APPDATA%/Racket on windows
and ~/.racket on Linux)
Thanks,
Alex.