extract_and_render: Extract notebooks and render as HTML

Description Usage Arguments Value

View source: R/extract_and_render.R

Description

Given a .tar.gz file, this function extracts all of the notebooks associated with the quiz_name, organizes them, and renders them as HTML. At the output_dir, two directories are created: source and html. The original .ipynb notebooks are renamed {username}_{quiz_name}.ipynb and put in the source directory, then they are rendered as html and the rendered files are put in the html directory.

Usage

1
2
3
4
5
6
7
8
extract_and_render(
  archive,
  course_name,
  quiz_name,
  output_dir,
  exclude = NULL,
  invert_exclusions = FALSE
)

Arguments

archive

The archive to extract the files from. This should be a gzipped tar archive. This is the same type of file created by the get_terminal_command function.

course_name

The name of the course to extract the notebooks from.

quiz_name

The name of the quiz to extract notebooks for.

output_dir

The directory the organized notebooks and HTML files should be output to. It is created if it does not exist.

exclude

A character vector of usernames to exclude from processing.

invert_exclusions

Invert the pattern matching triggered by exclude, essentially turning "exclude" into "keep only".

Value

The paths to the extracted notebooks (invisibly). The paths are relative to output_dir.


adamblake/nbsimplegrader_companion documentation built on April 19, 2020, 6:05 p.m.