From 3c28d82ddedf98932d3cef95dd5df0b0e423bce0 Mon Sep 17 00:00:00 2001 From: Ian Butterworth Date: Wed, 13 Dec 2023 15:06:07 -0500 Subject: [PATCH] pushfirst to standard_loadpath during init --- src/DataDeps.jl | 1 + src/locations.jl | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/src/DataDeps.jl b/src/DataDeps.jl index c9a2f1d..aa3d495 100644 --- a/src/DataDeps.jl +++ b/src/DataDeps.jl @@ -35,6 +35,7 @@ datadeps_scratch_dir = "" function __init__() global datadeps_scratch_dir = @get_scratch!("datadeps") + pushfirst!(standard_loadpath, datadeps_scratch_dir) end function _precompile_() diff --git a/src/locations.jl b/src/locations.jl index 9c2a22b..22e5111 100644 --- a/src/locations.jl +++ b/src/locations.jl @@ -15,7 +15,8 @@ const standard_loadpath = joinpath.([ "/usr/share", "/usr/local/share"] # Unix Filestructure end], "datadeps") -pushfirst!(standard_loadpath, joinpath(Base.DEPOT_PATH, "datadeps")) +# NOTE: the scratchspace is pushed to the front during __init__() + # ensure at least something in the loadpath exists when instaleld mkpath(first(standard_loadpath))