I've written a module in Julia using PkgTemplates package. The module is saved in C:/Users/me/.julia/dev/MyModule folder.
I cannot load the module in other sessions.
I've tried push!(LOAD_PATH, path) but didn't work.
Only include("C:/Users/me/dev/MyModule/src/MyModule.jl") works but in this case I can only use the functions in the module using MyModule.myfunction().
I couldn't find any other way to load the module.
You should use Pkg.develop (or pkg> develop in the Pkg REPL mode), see https://julialang.github.io/Pkg.jl/v1/managing-packages/#Adding-a-local-package-1. Pkg.develop is basically Pkg.add but you install from a local path, for example
julia> using Pkg
julia> Pkg.develop(PackageSpec(path = "C:/Users/me/dev/MyModule"))
or in the REPL mode:
pkg> develop C:/Users/me/dev/MyModule
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With