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

Add branch install notes to readme (plus clean up) #41

Merged
merged 34 commits into from
Sep 4, 2024
Merged
Show file tree
Hide file tree
Changes from 7 commits
Commits
Show all changes
34 commits
Select commit Hold shift + click to select a range
b3f229f
Bump roxygen2 version to latest
cjrace Jul 17, 2024
38c31e3
Add branch note to readme and copy text from dfeR, add contributing file
cjrace Jul 17, 2024
8feb243
add lintr config with limit matching CRAN and style_dir() to tidy code
cjrace Jul 17, 2024
4f47727
add PR template
cjrace Jul 17, 2024
dc3d07f
fix contributing headers
cjrace Jul 17, 2024
ee1bfbd
Merge branch 'main' into add-branch-install-readme
cjrace Jul 19, 2024
499e7ac
tidy up after conflict resolution
cjrace Jul 19, 2024
d7e7c93
attempt a github action for the test dashboard
cjrace Jul 19, 2024
239c9a4
try to stop false positives coming from global variable binding by pr…
cjrace Jul 19, 2024
1bc6dcb
remove renv from test dashboard yaml
cjrace Jul 19, 2024
e1a9530
fix typo in test_dashboard gha
cjrace Jul 19, 2024
0a94401
try adding devtools to description (test_dashboard gha)
cjrace Jul 19, 2024
1503c49
make sure that GHA will fail if the test dashboard tests fail
cjrace Jul 19, 2024
b52d5ca
Revert "make sure that GHA will fail if the test dashboard tests fail"
cjrace Jul 19, 2024
965e226
put the local package into the setup r dependencies step, update Code…
cjrace Jul 19, 2024
ff5c573
add a code of conduct (same as dfeR)
cjrace Jul 19, 2024
bf076b5
copy dfeR issue templates
cjrace Jul 19, 2024
cf1b92f
update test_dashboard tests (did some tidy up while looking at adding…
cjrace Jul 19, 2024
1db85ba
rebuild favicons to make them appear on pkgdown site
cjrace Jul 19, 2024
c6943f9
merge conflicts pulling main into this branch
cjrace Jul 23, 2024
1dcd864
linting and responding to test notes
cjrace Jul 23, 2024
6d3ca4f
fix brackets in code of conduct
cjrace Jul 23, 2024
07e010c
add missing families and update ids in test dashboard
cjrace Jul 23, 2024
7e353aa
Increment version number to 0.3.0
cjrace Jul 23, 2024
a6f879d
PR response and standardise examples / vignette for cookies
cjrace Jul 23, 2024
f48ebc4
Add init_analytics() into news!
cjrace Jul 23, 2024
c7ee853
remove duplicate branch install instructions (turns out we had added …
cjrace Jul 23, 2024
961e32f
run r cmd check on all pull requests
cjrace Jul 31, 2024
13d2188
Part 1 - update cookie to cookies (#42)
cjrace Aug 7, 2024
5593479
Part 2 - Make init code inline (#44)
cjrace Aug 19, 2024
8acf6aa
Part 3 - remove tab dependencies (#43)
cjrace Aug 29, 2024
22ae2ef
Clarified usethis makes blank scripts and have updated readme so user…
cjrace Sep 3, 2024
1859de9
update news.md with changes on this branch
cjrace Sep 3, 2024
c848f6b
update news.md
cjrace Sep 3, 2024
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
1 change: 1 addition & 0 deletions .Rbuildignore
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,4 @@
^_pkgdown\.yml$
^docs$
^pkgdown$
^.lintr$
71 changes: 71 additions & 0 deletions .github/CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
# Contributing to dfeshiny

Try and make use of the [usethis](https://usethis.r-lib.org/) package wherever possible.

When you initially clone the package, the first thing you'll need to do is install [devtools](https://devtools.r-lib.org/):

```
install.packages("devtools")
```

Then to load in the package in its current form:

```
devtools::load_all()
```

## Adding a package/dependency

`usethis::use_package(<package_name>)`

This will create a new script within the package R/ folder.
rmbielby marked this conversation as resolved.
Show resolved Hide resolved

Note that when adding a function from another package into one of the dfeshiny functions you will need to explicitly state the package in the function call, e.g.:

```package::function()```

Alternatively, if there's a lot of uses of a single function within one of our R scripts, you can call that function once at the top of the R script, e.g:

```
@' importFrom package function
```

For more information see the [roxygen2 documentation on declaring dependencies](https://roxygen2.r-lib.org/articles/namespace.html).

## Creating a new function script

`usethis::use_r(name = <script_name>)`

This will create a new script within the package R/ folder.

## Creating a new function test script

`usethis::use_test(name = <script_name>)`

This will create a new test script within the package testthat/ folder.
rmbielby marked this conversation as resolved.
Show resolved Hide resolved

## Updating the package version

Once changes have been completed, reviewed and are ready for use in the wild, you
can increment the package version using:

`usethis::use_version()`

Once you've incremented the version number, it'll add a new heading to news.md.

Add a summary under news.md and then accept it's offer to commit on your behalf.

Once pushed and on the main branch, create a new release in GitHub itself.

## Running tests

You should run the following lines to test the package locally:
```
# To check functionality
devtools::check() # Ctrl-Shft-E
shinytest2::test_app("tests/test_dashboard") # important as not currently ran in CI checks

# For code styling
styler::style_pkg()
lintr::lint_package()
```
24 changes: 24 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
<!--
Hey, thanks for raising a PR! We're excited to see what you've done!
To help us review the changes, please complete each section in this template by replacing '...' with details to help the reviewers of this pull request.
-->

# Brief overview of changes

...

## Why are these changes being made?

...

## Detailed description of changes

...

## Additional information for reviewers

...

## Issue ticket number/s and link

...
3 changes: 3 additions & 0 deletions .lintr
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
linters: linters_with_defaults(
line_length_linter = line_length_linter(100L) # limit CRAN sets for lines in PDF documentation
)
2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ Suggests:
Config/testthat/edition: 3
Encoding: UTF-8
Roxygen: list(markdown = TRUE)
RoxygenNote: 7.3.1
RoxygenNote: 7.3.2
URL: https://dfe-analytical-services.github.io/dfeshiny/
https://www.github.com/dfe-analytical-services/dfeshiny/
VignetteBuilder: knitr
Loading
Loading