Let’s try it out, with a simpler package.
$ mkdir /tmp/testdepot
$ JULIA_DEPOT_PATH=/tmp/testdepot julia
_
_ _ _(_)_ | Documentation: https://docs.julialang.org
(_) | (_) (_) |
_ _ _| |_ __ _ | Type "?" for help, "]?" for Pkg help.
| | | | | | |/ _` | |
| | |_| | | | (_| | | Version 1.10.7 (2024-11-26)
_/ |\__'_|_|_|\__'_| | Official https://julialang.org/ release
|__/ |
(@v1.10) pkg> add Example#master
Installing known registries into `/tmp/testdepot`
Added `General` registry to /tmp/testdepot/registries
Added `CVRegistry` registry to /tmp/testdepot/registries
Cloning git-repo `https://github.com/JuliaLang/Example.jl.git`
Updating git-repo `https://github.com/JuliaLang/Example.jl.git`
Updating registry at `/tmp/testdepot/registries/CVRegistry.toml`
Updating registry at `/tmp/testdepot/registries/General.toml`
Resolving package versions...
Updating `/tmp/testdepot/environments/v1.10/Project.toml`
[7876af07] + Example v0.5.5 `https://github.com/JuliaLang/Example.jl.git#master`
Updating `/tmp/testdepot/environments/v1.10/Manifest.toml`
[7876af07] + Example v0.5.5 `https://github.com/JuliaLang/Example.jl.git#master`
Precompiling project...
1 dependency successfully precompiled in 1 seconds
(@v1.10) pkg>
$ tree -d -L 3 /tmp/testdepot/
/tmp/testdepot/
├── clones
│ └── 4643033083726148914
│ ├── hooks
│ ├── info
│ ├── objects
│ └── refs
├── compiled
│ └── v1.10
│ └── Example
├── environments
│ └── v1.10
├── logs
├── packages
│ └── Example
│ └── A1z7K
├── registries
└── scratchspaces
└── 44cfe95a-1eb2-52ea-b672-e2afdf69b78f
It’s maybe not completely obvious but I interpret this to be that we have a clone of the Example repository in clones and a snapshot of the master branch in packages. When you don’t set JULIA_DEPOT_PATH those would be inside your .julia directory.
The subdirectory name A1z7K is computed from some information that I don’t remember in detail but you can find it for the loaded version of the package with pathof. I have never looked into the naming of the subdirectories of clones.