From edb70503241ba1fd204f48317794b3b6cf858e0e Mon Sep 17 00:00:00 2001 From: Valentin Churavy Date: Thu, 12 Oct 2023 07:47:49 -0400 Subject: [PATCH 1/3] adjust to franklin style --- src/Actions.jl | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/src/Actions.jl b/src/Actions.jl index df6ca1b..063de6e 100644 --- a/src/Actions.jl +++ b/src/Actions.jl @@ -186,17 +186,16 @@ function generate_static_export( start_dir, ) pluto_version = try_get_exact_pluto_version() + relative_to_notebooks_dir = without_pluto_file_extension(path) export_jl_path = let - relative_to_notebooks_dir = path - joinpath(output_dir, relative_to_notebooks_dir) + joinpath(output_dir, relative_to_notebooks_dir, filename(path)) end export_html_path = let - relative_to_notebooks_dir = without_pluto_file_extension(path) * ".html" - joinpath(output_dir, relative_to_notebooks_dir) + joinpath(output_dir, relative_to_notebooks_dir, "index.html") end export_statefile_path = let - relative_to_notebooks_dir = without_pluto_file_extension(path) * ".plutostate" - joinpath(output_dir, relative_to_notebooks_dir) + joinpath(output_dir, relative_to_notebooks_dir, + without_pluto_file_extension(filename(path)) * ".plutostate" end @@ -220,7 +219,7 @@ function generate_static_export( end slider_server_url_js = if slider_server_running_somewhere abs_path = joinpath(start_dir, path) - url_of_root = relpath(start_dir, dirname(abs_path)) # e.g. "." or "../../.." + url_of_root = relpath(start_dir, dirname(abs_path)) # e.g. "." or "../../.." repr(something(settings.Export.slider_server_url, url_of_root)) else "undefined" @@ -302,4 +301,4 @@ function remove_static_export(path; settings, output_dir) !settings.Export.baked_notebookfile tryrm(export_jl_path) end -end \ No newline at end of file +end From 1ce76aac0e6250362a391213920fd48d0367eacb Mon Sep 17 00:00:00 2001 From: Valentin Churavy Date: Thu, 12 Oct 2023 07:48:43 -0400 Subject: [PATCH 2/3] fixup! adjust to franklin style --- src/Actions.jl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Actions.jl b/src/Actions.jl index 063de6e..5b6ca3e 100644 --- a/src/Actions.jl +++ b/src/Actions.jl @@ -195,7 +195,7 @@ function generate_static_export( end export_statefile_path = let joinpath(output_dir, relative_to_notebooks_dir, - without_pluto_file_extension(filename(path)) * ".plutostate" + without_pluto_file_extension(filename(path)) * ".plutostate") end From c763bd3a919184825d8a2c281482c982aee5fe24 Mon Sep 17 00:00:00 2001 From: Valentin Churavy Date: Thu, 12 Oct 2023 07:51:49 -0400 Subject: [PATCH 3/3] fixup! adjust to franklin style --- src/Actions.jl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Actions.jl b/src/Actions.jl index 5b6ca3e..19cd54a 100644 --- a/src/Actions.jl +++ b/src/Actions.jl @@ -188,14 +188,14 @@ function generate_static_export( pluto_version = try_get_exact_pluto_version() relative_to_notebooks_dir = without_pluto_file_extension(path) export_jl_path = let - joinpath(output_dir, relative_to_notebooks_dir, filename(path)) + joinpath(output_dir, relative_to_notebooks_dir, basename(path)) end export_html_path = let joinpath(output_dir, relative_to_notebooks_dir, "index.html") end export_statefile_path = let joinpath(output_dir, relative_to_notebooks_dir, - without_pluto_file_extension(filename(path)) * ".plutostate") + without_pluto_file_extension(basename(path)) * ".plutostate") end