diff --git a/Project.toml b/Project.toml index 22f5caf..6854eb9 100644 --- a/Project.toml +++ b/Project.toml @@ -12,6 +12,7 @@ Mustache = "ffc61752-8dc7-55ee-8c37-f3e9cdd09e70" Pkg = "44cfe95a-1eb2-52ea-b672-e2afdf69b78f" Printf = "de0858da-6303-5e67-8744-51eddeeeb8d7" REPL = "3fa0cd96-eef1-5676-8a61-b3b8758bbffb" +RelocatableFolders = "05181044-ff0b-4ac5-8273-598c1e38db00" Requires = "ae029012-a4dd-5104-9daa-d747884805df" Serialization = "9e88b42a-f829-5b0c-bbe9-9e923198166b" YAML = "ddb6d928-2868-570f-bddf-ab3f9cf99eb6" diff --git a/src/Weave.jl b/src/Weave.jl index c58640a..a873bc6 100644 --- a/src/Weave.jl +++ b/src/Weave.jl @@ -1,14 +1,13 @@ module Weave -using Highlights, Mustache, Requires, Pkg, REPL - +using Highlights, Mustache, Requires, Pkg, REPL, RelocatableFolders # directories const PKG_DIR = normpath(@__DIR__, "..") -const TEMPLATE_DIR = normpath(PKG_DIR, "templates") -const STYLESHEET_DIR = normpath(PKG_DIR, "stylesheets") +const TEMPLATE_DIR = @path joinpath(PKG_DIR, "templates") +const STYLESHEET_DIR = @path joinpath(PKG_DIR, "stylesheets") # keeps paths of sample documents for easy try -const EXAMPLE_FOLDER = normpath(PKG_DIR, "examples") +const EXAMPLE_FOLDER = @path joinpath(PKG_DIR, "examples") # constant names const WEAVE_OPTION_NAME = "weave_options"