Skip to content

Commit bf6c31c

Browse files
docs: add notes about scratchspaces in depot (#52367)
Co-authored-by: Fredrik Ekre <ekrefredrik@gmail.com>
1 parent 3b9c39a commit bf6c31c

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

base/initdefs.jl

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,13 +73,21 @@ environment variable if set.
7373
Each entry in `DEPOT_PATH` is a path to a directory which contains subdirectories used by Julia for various purposes.
7474
Here is an overview of some of the subdirectories that may exist in a depot:
7575
76+
* `artifacts`: Contains content that packages use for which Pkg manages the installation of.
7677
* `clones`: Contains full clones of package repos. Maintained by `Pkg.jl` and used as a cache.
78+
* `config`: Contains julia-level configuration such as a `startup.jl`
7779
* `compiled`: Contains precompiled `*.ji` files for packages. Maintained by Julia.
7880
* `dev`: Default directory for `Pkg.develop`. Maintained by `Pkg.jl` and the user.
7981
* `environments`: Default package environments. For instance the global environment for a specific julia version. Maintained by `Pkg.jl`.
8082
* `logs`: Contains logs of `Pkg` and `REPL` operations. Maintained by `Pkg.jl` and `Julia`.
8183
* `packages`: Contains packages, some of which were explicitly installed and some which are implicit dependencies. Maintained by `Pkg.jl`.
8284
* `registries`: Contains package registries. By default only `General`. Maintained by `Pkg.jl`.
85+
* `scratchspaces`: Contains content that a package itself installs via the [`Scratch.jl`](https://github.com/JuliaPackaging/Scratch.jl) package. `Pkg.gc()` will delete content that is known to be unused.
86+
87+
!!! note
88+
Packages that want to store content should use the `scratchspaces` subdirectory via
89+
[`Scratch.jl`](https://github.com/JuliaPackaging/Scratch.jl) instead of creating new
90+
subdirectories in the depot root.
8391
8492
See also [`JULIA_DEPOT_PATH`](@ref JULIA_DEPOT_PATH), and
8593
[Code Loading](@ref code-loading).

0 commit comments

Comments
 (0)