This is a higher level function that automates the common steps for setting up grading of an assignment:
Find repos matching a filter pattern in an organization
Clone all matched repos locally
Download GitHub Actions artifacts (e.g. rendered html, md files)
Report any missing artifacts
Create comment template files for each repo
org_grade_assignment(
path,
org,
repo_filter,
artifacts = character(),
comment_template = "",
key_repo = NULL
)An invisible list containing:
repos — character vector of matched repo addresses
cloned — result from local_repo_clone()
artifacts — named list of results from each action_artifact_download() call
comments — character vector of comment file paths created
key — result from cloning the key repo (if provided)
Character. Root directory for the grading folder (created if it doesn't exist).
Character. Name of the GitHub organization.
Character. Regex pattern passed to org_repos()'s filter
argument to select repos (e.g. "hw01_").
Named character vector. Names are subfolder names, values are
regex patterns passed as filter to action_artifact_download() (matched
against artifact names). E.g. c("html" = "html-output", "report" = "pdf-report").
Character. Template text used to populate each comment
markdown file. Defaults to "".
Character. Optional repository address in owner/name format
to clone into the root of the grading folder as an answer key.