Skip to content

Commit

Permalink
Fix #166, fix #169
Browse files Browse the repository at this point in the history
  • Loading branch information
wlandau committed Mar 18, 2024
1 parent 4543c53 commit 81d59e4
Show file tree
Hide file tree
Showing 10 changed files with 40 additions and 3 deletions.
2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ Description: Function-oriented Make-like declarative pipelines for
reproducible pipelines concisely and compactly.
The methods in this package were influenced by the 'drake' R package
by Will Landau (2018) <doi:10.21105/joss.00550>.
Version: 0.7.12.9002
Version: 0.8.0
License: MIT + file LICENSE
URL: https://docs.ropensci.org/tarchetypes/, https://github.com/ropensci/tarchetypes
BugReports: https://github.com/ropensci/tarchetypes/issues
Expand Down
5 changes: 3 additions & 2 deletions NEWS.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
# tarchetypes 0.7.12.9002 (development)
# tarchetypes 0.8.0

* Expose the new `description` argument of `tar_target()` in `targets` 1.5.1.9001.
* `tar_map()` and other static branching target factories now append values to the target descriptions. Use the `descriptions` argument of those functions to customize.
* Ensure consistent `repository` settings in `tar_change()` and `tar_map_rep()`.
* `tar_knit()`, `tar_render()`, `tar_quarto()`, and their "rep" and "raw" versions all gain a `working_directory` argument to change the working directory the report knits from. Users who set `working_directory` need to supply the `store` argument of `tar_load()` and `tar_read()` relative to the working directory so the report knows where to find the data.
* `tar_knit()`, `tar_render()`, `tar_quarto()`, and their "rep" and "raw" versions all gain a `working_directory` argument to change the working directory the report knits from. Users who set `working_directory` need to supply the `store` argument of `tar_load()` and `tar_read()` relative to the working directory so the report knows where to find the data (#169).
* `tar_knit()`, `tar_render()`, `tar_quarto()`, and their "raw" versions all gain an `output_file` argument to more conveniently set the file path to the rendered output file.
* `tar_quarto()` and its "rep" and "raw" versions all gain a new `quarto_args` argument for advanced Quarto arguments (#166, @petrbouchal).

# tarchetypes 0.7.12

Expand Down
2 changes: 2 additions & 0 deletions R/tar_quarto.R
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,7 @@ tar_quarto <- function(
cache_refresh = FALSE,
debug = FALSE,
quiet = TRUE,
quarto_args = NULL,
pandoc_args = NULL,
profile = NULL,
tidy_eval = targets::tar_option_get("tidy_eval"),
Expand Down Expand Up @@ -157,6 +158,7 @@ tar_quarto <- function(
cache_refresh = cache_refresh,
debug = debug,
quiet = quiet,
quarto_args = quarto_args,
pandoc_args = pandoc_args,
profile = profile,
packages = packages,
Expand Down
6 changes: 6 additions & 0 deletions R/tar_quarto_raw.R
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,7 @@ tar_quarto_raw <- function(
cache_refresh = FALSE,
debug = FALSE,
quiet = TRUE,
quarto_args = NULL,
pandoc_args = NULL,
profile = NULL,
packages = NULL,
Expand Down Expand Up @@ -153,6 +154,7 @@ tar_quarto_raw <- function(
targets::tar_assert_lgl(debug)
targets::tar_assert_scalar(quiet)
targets::tar_assert_lgl(quiet)
targets::tar_assert_chr(quarto_args %|||% ".")
targets::tar_assert_chr(pandoc_args %|||% ".")
targets::tar_assert_scalar(profile %|||% ".")
targets::tar_assert_chr(profile %|||% ".")
Expand Down Expand Up @@ -180,6 +182,7 @@ tar_quarto_raw <- function(
cache_refresh = cache_refresh,
debug = debug,
quiet = quiet,
quarto_args = quarto_args,
pandoc_args = pandoc_args,
profile = profile
)
Expand Down Expand Up @@ -212,6 +215,7 @@ tar_quarto_command <- function(
cache_refresh,
debug,
quiet,
quarto_args,
pandoc_args,
profile
) {
Expand All @@ -228,6 +232,7 @@ tar_quarto_command <- function(
cache_refresh = cache_refresh,
debug = debug,
quiet = quiet,
quarto_args = quarto_args,
pandoc_args = pandoc_args,
as_job = FALSE
),
Expand All @@ -240,6 +245,7 @@ tar_quarto_command <- function(
cache_refresh = cache_refresh,
debug = debug,
quiet = quiet,
quarto_args = quarto_args,
pandoc_args = pandoc_args
)
)
Expand Down
2 changes: 2 additions & 0 deletions R/tar_quarto_rep.R
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,7 @@ tar_quarto_rep <- function(
cache_refresh = FALSE,
debug = FALSE,
quiet = TRUE,
quarto_args = NULL,
pandoc_args = NULL,
rep_workers = 1,
tidy_eval = targets::tar_option_get("tidy_eval"),
Expand Down Expand Up @@ -138,6 +139,7 @@ tar_quarto_rep <- function(
cache_refresh = cache_refresh,
debug = debug,
quiet = quiet,
quarto_args = quarto_args,
pandoc_args = pandoc_args,
rep_workers = rep_workers,
packages = packages,
Expand Down
6 changes: 6 additions & 0 deletions R/tar_quarto_rep_raw.R
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,7 @@ tar_quarto_rep_raw <- function(
cache_refresh = FALSE,
debug = FALSE,
quiet = TRUE,
quarto_args = NULL,
pandoc_args = NULL,
rep_workers = 1,
packages = targets::tar_option_get("packages"),
Expand Down Expand Up @@ -158,6 +159,7 @@ tar_quarto_rep_raw <- function(
targets::tar_assert_lgl(debug)
targets::tar_assert_scalar(quiet)
targets::tar_assert_lgl(quiet)
targets::tar_assert_chr(quarto_args %|||% ".")
targets::tar_assert_chr(pandoc_args %|||% ".")
tar_assert_rep_workers(rep_workers)
rep_workers <- as.integer(rep_workers)
Expand Down Expand Up @@ -199,6 +201,7 @@ tar_quarto_rep_raw <- function(
cache_refresh = cache_refresh,
debug = debug,
quiet = quiet,
quarto_args = quarto_args,
pandoc_args = pandoc_args,
default_output_file = default_output_file,
rep_workers = rep_workers
Expand Down Expand Up @@ -309,6 +312,7 @@ tar_quarto_rep_command <- function(
cache_refresh,
debug,
quiet,
quarto_args,
pandoc_args,
default_output_file,
rep_workers
Expand All @@ -325,6 +329,7 @@ tar_quarto_rep_command <- function(
cache_refresh = cache_refresh,
debug = debug,
quiet = quiet,
quarto_args = quarto_args,
pandoc_args = pandoc_args,
as_job = FALSE
),
Expand All @@ -336,6 +341,7 @@ tar_quarto_rep_command <- function(
cache_refresh = cache_refresh,
debug = debug,
quiet = quiet,
quarto_args = quarto_args,
pandoc_args = pandoc_args
)
)
Expand Down
5 changes: 5 additions & 0 deletions man/tar_quarto.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 5 additions & 0 deletions man/tar_quarto_raw.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 5 additions & 0 deletions man/tar_quarto_rep.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 5 additions & 0 deletions man/tar_quarto_rep_raw.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 81d59e4

Please sign in to comment.