Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

More work on vignettes #879

Merged
merged 27 commits into from
Nov 18, 2022
Merged
Show file tree
Hide file tree
Changes from 12 commits
Commits
Show all changes
27 commits
Select commit Hold shift + click to select a range
fa0db16
Combining this with man.Rmd seems like a bad idea
jennybc Nov 8, 2022
4e13026
Stage should be "polishing" by the time this PR is merged
jennybc Nov 8, 2022
f05b364
Work on the introduction
jennybc Nov 10, 2022
13f31d1
Work on the (first) workflow section
jennybc Nov 10, 2022
ece609b
Describe the vignette template
jennybc Nov 10, 2022
8b5fc2c
Move backtick
jennybc Nov 10, 2022
ccde0fb
Tweaks
jennybc Nov 10, 2022
f1a204b
Writing advice and conditional execution
jennybc Nov 11, 2022
da30f89
Fresh eyes
jennybc Nov 11, 2022
3aaa8a8
More fresh eyes
jennybc Nov 12, 2022
21dd700
Done, for now
jennybc Nov 16, 2022
8991c81
Tweaks based on reading a rendered preview
jennybc Nov 16, 2022
e7ac2c3
Add a section on links
jennybc Nov 17, 2022
b394952
Add a callout re: prebuilt vignettes and the like
jennybc Nov 17, 2022
17362fa
Apply suggestions from code review
jennybc Nov 17, 2022
076539a
Linebreak
jennybc Nov 17, 2022
a8bad29
Explain that Sweave generally leads to PDF
jennybc Nov 17, 2022
cba7cba
Say more about building against the current source
jennybc Nov 17, 2022
0646ba4
Advise against load_all() in a vignette
jennybc Nov 17, 2022
e05b95c
Fresh eyes
jennybc Nov 17, 2022
31aa8cb
Improve coverage of articles
jennybc Nov 17, 2022
f9d37e8
Remove two labels that don't follow current convention
jennybc Nov 18, 2022
afeb999
This order makes more sense to me
jennybc Nov 18, 2022
8f7f27b
Add section on file paths
jennybc Nov 18, 2022
d4f2a58
Add sf as example of system.file()
jennybc Nov 18, 2022
8cc1249
Add the comparison to function documentation
jennybc Nov 18, 2022
d1a905d
Final pass
jennybc Nov 18, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion man.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -753,7 +753,7 @@ For the initial CRAN submission of your package, all functions must have at leas
If the code can only be run under specific conditions, use the techniques below to express those pre-conditions.
:::
### Dependencies and conditional execution
### Dependencies and conditional execution {#sec-man-examples-dependencies-conditional-execution}
An additional source of errors in examples is the use of external dependencies: you can only use packages in your examples that your package formally depends on (i.e. that appear in `Imports` or `Suggests`).
Furthermore, example code is run in the user's environment, not the package environment, so you'll have to either explicitly attach the dependency with `library()` or refer to each function with `::`.
Expand Down
2 changes: 1 addition & 1 deletion structure.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ Examples:
Note that exploring a package's source and history within the `cran` GitHub organisation is not the same as exploring the package's true development venue, because this source and its evolution is just reverse-engineered from the package's CRAN releases.
This presents a redacted view of the package and its history, but, by definition, it includes everything that is essential.

## Bundled package
## Bundled package {#sec-bundled-package}

A **bundled** package is a package that's been compressed into a single file.
By convention (from Linux), package bundles in R use the extension `.tar.gz` and are sometimes referred to as "source tarballs".
Expand Down
2 changes: 1 addition & 1 deletion testing-design.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ We use covr regularly, in two different ways:
- Local, interactive use. We mostly use `devtools::test_coverage_active_file()` and `devtools::test_coverage()`, for exploring the coverage of an individual file or the whole package, respectively.
- Automatic, remote use via GitHub Actions (GHA). We cover continuous integration and GHA more thoroughly elsewhere, but we will at least mention here that `usethis::use_github_action("test-coverage")` configures a GHA workflow that constantly monitors your test coverage. Test coverage can be an especially helpful metric when evaluating a pull request (either your own or from an external contributor). A proposed change that is well-covered by tests is less risky to merge.

## High-level principles for testing
## High-level principles for testing {#sec-testing-design-principles}

In later sections, we offer concrete strategies for how to handle common testing dilemmas in R.
Here we lay out the high-level principles that underpin these recommendations:
Expand Down
Loading