ecohealthalliance / open-rvfcast

Wellcome Open RVFCast project repository
Other
0 stars 2 forks source link

Add names of targets in tar_plans to environment #73

Closed noamross closed 11 months ago

noamross commented 11 months ago

This tweak to all_targets() adds the feature that, if the environment has lists of targets, such as those created by tar_plan(), it will assign a vector of those targets' names to the environment, using the name of the list object. This overwrites the list objects, but that's OK, because we have already collected them as part of the output. This means, for each list of targets, one can call any targets function with the name of the list, e.g, tar_make(static_targets), or tar_visnetwork(targets_only = TRUE, static_targets). It will not work with things like tar_load(), which do not actually run _targets.R.