Skip to content

Commit

Permalink
Merge pull request #16 from JuliaPluto/kwarg-override-support
Browse files Browse the repository at this point in the history
  • Loading branch information
fonsp authored Aug 10, 2024
2 parents 41b228a + 96fe01e commit ea955e5
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 6 deletions.
2 changes: 1 addition & 1 deletion Project.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name = "PlutoPages"
uuid = "d5dc3dd1-4774-47c7-8860-0a1ad9e34b8c"
authors = ["Luca Ferranti", "Fons van der Plas"]
version = "0.1.4"
version = "0.1.5"

[deps]
BetterFileWatching = "c9fd44ac-77b5-486c-9482-9798bd063cc6"
Expand Down
6 changes: 3 additions & 3 deletions src/PlutoPages.jl
Original file line number Diff line number Diff line change
Expand Up @@ -94,8 +94,8 @@ function create_subdirs(root_dir::String)
)
end

function develop(root_dir::String)
develop(;create_subdirs(root_dir)...)
function develop(root_dir::String; kwargs...)
develop(;create_subdirs(root_dir)..., kwargs...)
end


Expand Down Expand Up @@ -199,7 +199,7 @@ function generate(;
return output_dir
end

generate(root_dir::String) = generate(;create_subdirs(root_dir)...)
generate(root_dir::String; kwargs...) = generate(;create_subdirs(root_dir)..., kwargs...)


function create_test_basic_site()
Expand Down
6 changes: 4 additions & 2 deletions test/runtests.jl
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,9 @@ using Test

dirs = PlutoPages.create_subdirs(input_dir)

result = PlutoPages.generate(; dirs...)
html_report_path = tempname(cleanup=false)

result = PlutoPages.generate(; dirs..., html_report_path)
@test result == dirs.output_dir

@info "Done!" dirs readdir(dirs.input_dir) readdir(dirs.output_dir)
Expand All @@ -22,5 +24,5 @@ using Test
@test isfile(joinpath(dirs.output_dir, "en", "blog", "something", "index.html"))
@test isfile(joinpath(dirs.output_dir, "en", "blog", "yayy", "index.html"))


@test isfile(html_report_path)
end

2 comments on commit ea955e5

@fonsp
Copy link
Member Author

@fonsp fonsp commented on ea955e5 Aug 10, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@JuliaRegistrator register()

@JuliaRegistrator
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Registration pull request created: JuliaRegistries/General/112841

Tip: Release Notes

Did you know you can add release notes too? Just add markdown formatted text underneath the comment after the text
"Release notes:" and it will be added to the registry PR, and if TagBot is installed it will also be added to the
release that TagBot creates. i.e.

@JuliaRegistrator register

Release notes:

## Breaking changes

- blah

To add them here just re-invoke and the PR will be updated.

Tagging

After the above pull request is merged, it is recommended that a tag is created on this repository for the registered package version.

This will be done automatically if the Julia TagBot GitHub Action is installed, or can be done manually through the github interface, or via:

git tag -a v0.1.5 -m "<description of version>" ea955e50c2583aa3b59948227d24b027d1701ef2
git push origin v0.1.5

Please sign in to comment.