Skip to content

Commit

Permalink
change path again
Browse files Browse the repository at this point in the history
  • Loading branch information
jkrumbiegel committed May 23, 2024
1 parent 82685b4 commit f9db7d9
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 2 additions & 2 deletions docs/buildutils/redirect_generation.jl
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
function generate_redirects(rules; dry_run = true)
htmlpaths = cd("../build/final_site") do
htmlpaths = cd(joinpath("build", "final_site")) do
collect(Iterators.flatmap(walkdir(".")) do (root, dirs, files)
(chop(joinpath(root, file), head = 1, tail = 0) for file in files if endswith(file, ".html"))
end)
Expand Down Expand Up @@ -34,7 +34,7 @@ function write_redirection_html(redirect_file, existing_file; dry_run)

@info "Adding redirect from $redirect_file to $existing_file"
if !dry_run
cd("../build/final_site") do
cd(joinpath("build", "final_site")) do
filepath = "." * redirect_file
mkpath(splitdir(filepath)[1])
open(filepath, "w") do io
Expand Down
2 changes: 2 additions & 0 deletions docs/makedocs.jl
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,9 @@ Documenter.makedocs(;

@show pwd()
run(`ls`)
println()
run(`ls ..`)
println()
cd(@__DIR__)

generate_redirects([
Expand Down

0 comments on commit f9db7d9

Please sign in to comment.