script_check: Check an R script for presence of affected object changes

Description Usage Arguments Value Examples

View source: R/tree_extract.R

Description

Check an R script for presence of affected object changes

Usage

1
2
3
4
5
6
7
script_check(
  compare_object,
  script_filepath,
  is_R_script = T,
  include_specials = F,
  summary_file = ""
)

Arguments

compare_object

Comparison object of two inventories as returned by 'compare_inventory'.

script_filepath

Filepath to a script of interest.

is_R_script

Logical. Default is TRUE, which assumes the script is a .R file. If FALSE, applies 'knitr::purl' to convert to a .R script prior to parsing.

include_specials

Logical. Whether to include special characters as objects when searching script.

summary_file

Character. Default is '""', which prints resulting summary to the console. If a filepath to a .txt file is provided, summary will save to the file instead.

Value

Concatenated summary of whether script involves any affected objects from the inventory comparison object.

Examples

1
## Not run: script_check(compare_object, script_filepath, summary_file = "script-check-results.txt")

kiegan/manager documentation built on Sept. 24, 2020, 10:59 p.m.