Skip to content

setup_readme(): add the has_example argument the guide documents, template example section (supersedes #24) #74

Description

@larnsce

The ghedatapublishing guide instructs readers to run setup_readme(has_example = TRUE), but setup_readme() takes no arguments; has_example belongs to setup_website(). The guide documents an API the package does not have.

Tasks:

  • Add has_example to setup_readme() (consistent semantics with setup_website's argument), or make one function own the concept and update the guide accordingly
  • README template gains an Example section with a commented ggplot2 scaffold, matching the guide's "create a data visualization" step; this absorbs the intent of Templates for plots and tables #24 (plot/table templates), which can then be closed as superseded
  • Also fix the fragile first-dataset lookup (list.files("data")[1] yields NA on an empty data dir and only warns after the fact)

Acceptance: the guide's documented call works; a new package gets a README template whose example section compiles once a dataset name is filled in.

Depends on the setup_readme data-loss fix shipping first (v1.0.2). Milestone: v1.1.0 (set manually, see the milestone setup issue).

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions