Skip to content

Commit 39a8875

Browse files
authored
Merge pull request #1245 from ThinkR-open/temp-dev
Batch integration: temp-dev → master (golem 0.6.0)
2 parents cd21dbc + 8d46a1d commit 39a8875

100 files changed

Lines changed: 7387 additions & 603 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.claude/settings.local.json

Lines changed: 0 additions & 13 deletions
This file was deleted.

.github/workflows/R-CMD-check.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22
# Need help debugging build failures? Start at https://github.com/r-lib/actions#where-to-find-help
33
on:
44
push:
5-
branches: [main, master, dev]
5+
branches: [main, master, "*dev*"]
66
pull_request:
7-
branches: [main, master, dev]
7+
branches: [main, master, "*dev*"]
88

99
name: R-CMD-check
1010

@@ -29,7 +29,7 @@ jobs:
2929
R_KEEP_PKG_SOURCE: yes
3030

3131
steps:
32-
- uses: actions/checkout@v3
32+
- uses: actions/checkout@v4
3333

3434
- uses: r-lib/actions/setup-pandoc@v2
3535

.github/workflows/pkgdown.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ jobs:
1717
permissions:
1818
contents: write
1919
steps:
20-
- uses: actions/checkout@v3
20+
- uses: actions/checkout@v4
2121

2222
- uses: r-lib/actions/setup-pandoc@v2
2323

.github/workflows/pr-commands.yaml

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,11 @@ jobs:
1010
env:
1111
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
1212
steps:
13-
- uses: actions/checkout@v2
14-
- uses: r-lib/actions/pr-fetch@v1
13+
- uses: actions/checkout@v4
14+
- uses: r-lib/actions/pr-fetch@v2
1515
with:
1616
repo-token: ${{ secrets.GITHUB_TOKEN }}
17-
- uses: r-lib/actions/setup-r@v1
17+
- uses: r-lib/actions/setup-r@v2
1818
- name: Install dependencies
1919
run: Rscript -e 'install.packages(c("remotes", "roxygen2"))' -e 'remotes::install_deps(dependencies = TRUE)'
2020
- name: Document
@@ -25,7 +25,7 @@ jobs:
2525
git config --local user.name "GitHub Actions"
2626
git add man/\* NAMESPACE
2727
git commit -m 'Document'
28-
- uses: r-lib/actions/pr-push@v1
28+
- uses: r-lib/actions/pr-push@v2
2929
with:
3030
repo-token: ${{ secrets.GITHUB_TOKEN }}
3131
style:
@@ -35,11 +35,11 @@ jobs:
3535
env:
3636
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
3737
steps:
38-
- uses: actions/checkout@v2
39-
- uses: r-lib/actions/pr-fetch@v1
38+
- uses: actions/checkout@v4
39+
- uses: r-lib/actions/pr-fetch@v2
4040
with:
4141
repo-token: ${{ secrets.GITHUB_TOKEN }}
42-
- uses: r-lib/actions/setup-r@v1
42+
- uses: r-lib/actions/setup-r@v2
4343
- name: Install dependencies
4444
run: Rscript -e 'install.packages("styler")'
4545
- name: Style
@@ -50,6 +50,6 @@ jobs:
5050
git config --local user.name "GitHub Actions"
5151
git add \*.R
5252
git commit -m 'Style'
53-
- uses: r-lib/actions/pr-push@v1
53+
- uses: r-lib/actions/pr-push@v2
5454
with:
5555
repo-token: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/render-rmarkdown-and-bump-version.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ jobs:
1616
steps:
1717
# Checks-out golem repo so the job can access it
1818
- name: Checkout repo
19-
uses: actions/checkout@v3
19+
uses: actions/checkout@v4
2020
with:
2121
fetch-depth: 0
2222
- uses: r-lib/actions/setup-pandoc@v2

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,3 +13,4 @@ README.html
1313
*.Rproj
1414
/doc/
1515
/Meta/
16+
.claude/settings.local.json

DESCRIPTION

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
Package: golem
22
Title: A Framework for Robust Shiny Applications
3-
Version: 0.5.1.9016
3+
Version: 0.6.0
44
Authors@R: c(
55
person("Colin", "Fay", , "contact@colinfay.me", role = c("cre", "aut"),
66
comment = c(ORCID = "0000-0001-7343-1846")),
@@ -39,7 +39,6 @@ Suggests:
3939
callr,
4040
cli (>= 2.0.0),
4141
covr,
42-
crayon,
4342
desc,
4443
devtools,
4544
dockerfiler (>= 0.2.5),
@@ -72,4 +71,4 @@ Config/testthat/edition: 3
7271
Encoding: UTF-8
7372
Language: en-US
7473
Roxygen: list(markdown = TRUE)
75-
RoxygenNote: 7.3.2
74+
RoxygenNote: 7.3.3

NAMESPACE

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,8 @@ export(add_dockerfile_with_renv_heroku)
1010
export(add_dockerfile_with_renv_shinyproxy)
1111
export(add_empty_file)
1212
export(add_fct)
13+
export(add_github_action)
14+
export(add_gitlab_ci)
1315
export(add_html_template)
1416
export(add_js_file)
1517
export(add_js_handler)
@@ -21,7 +23,6 @@ export(add_positconnect_file)
2123
export(add_r6)
2224
export(add_resource_path)
2325
export(add_rscignore_file)
24-
export(add_rstudioconnect_file)
2526
export(add_sass_file)
2627
export(add_shinyappsio_file)
2728
export(add_shinyserver_file)
@@ -45,13 +46,13 @@ export(expect_running)
4546
export(expect_shinytag)
4647
export(expect_shinytaglist)
4748
export(favicon)
49+
export(fct_template)
4850
export(fill_desc)
4951
export(get_current_config)
5052
export(get_golem_name)
5153
export(get_golem_options)
5254
export(get_golem_version)
5355
export(get_golem_wd)
54-
export(get_sysreqs)
5556
export(golem_welcome_page)
5657
export(install_dev_deps)
5758
export(invoke_js)
@@ -76,6 +77,9 @@ export(set_golem_name)
7677
export(set_golem_options)
7778
export(set_golem_version)
7879
export(set_golem_wd)
80+
export(use_agent_skills)
81+
export(use_bundled_html)
82+
export(use_claude_skills)
7983
export(use_external_css_file)
8084
export(use_external_file)
8185
export(use_external_html_template)
@@ -87,8 +91,9 @@ export(use_internal_html_template)
8791
export(use_internal_js_file)
8892
export(use_module_test)
8993
export(use_readme_rmd)
90-
export(use_recommended_deps)
9194
export(use_recommended_tests)
95+
export(use_skill)
96+
export(use_skills)
9297
export(use_utils_server)
9398
export(use_utils_test_server)
9499
export(use_utils_test_ui)

NEWS.md

Lines changed: 45 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,28 +4,70 @@
44

55
## New features / user-visible changes
66

7+
- New `use_skills()`, `use_agent_skills()`, `use_claude_skills()` and
8+
`use_skill()` helpers install agent skills (Claude Code / AGENTS.md
9+
layouts) into a `{golem}` project, from the package's bundled skills or
10+
from the upstream `ThinkR-open/golem-agent-skills` repository
11+
(@ilyaZar, #1233).
12+
- `create_golem()` gains `with_agents` and `with_agents_options` arguments
13+
to optionally install agent skills during project creation, and the
14+
RStudio "New Project" wizard exposes a matching set of options
15+
(@ilyaZar, #1233).
16+
- Installing agent skills now appends the corresponding entries
17+
(`^\.claude$`, `^CLAUDE\.md$`, `^\.agents$`, `^AGENTS\.md$`) to the
18+
project's `.Rbuildignore` so `R CMD check` no longer flags them as
19+
non-standard top-level files.
20+
- New `add_github_action()` and `add_gitlab_ci()` helpers generate minimal
21+
deployment CI for fresh `{golem}` apps.
22+
- The deployment CI helpers restore `renv.lock` when it is present, fall back
23+
to `DESCRIPTION` when it is not, and declare `{pkgload}` for the generated
24+
Posit Connect entrypoint.
725
- The `add_dockerfile_with_renv_*` function now generates a multi-stage Dockerfile by default (use `single_file = FALSE` to retain the previous behavior).
826
- The `add_dockerfile_with_renv_*` function now creates a Dockerfile that sets `golem.app.prod = TRUE` by default (use `set_golem.app.prod = FALSE` to retain the previous behavior).
927
- Print functions have be reworked standardized using the `{cli}` package (@ilyaZar, #89)
28+
- `use_bundled_html()` downloads bundled HTML templates as zip archives, optionally extracts them into `inst/app/www`, and can remove the raw zip afterwards (#848)
29+
30+
- `add_fct()` gains a `template` argument to customize the content of the generated file; the default template is now exposed as the exported `fct_template()` function, mirroring the `module_template()` / `add_module()` pattern (@ilyaZar, #838)
31+
32+
- `add_js_input_binding()` and `add_js_output_binding()` now generate a functional binding: the JS file contains working `find`, `getValue`/`renderValue`, `setValue`, `receiveMessage`, and `subscribe` implementations, and an R companion file (`fct_<name>_input_binding.R` / `fct_<name>_output_binding.R`) is created alongside it with ready-to-use UI constructor, update, and render functions (@ilyaZar, #868, #869)
1033

1134
## Breaking change
1235

1336
- The `get_current_config()` has been rework in two ways: (1) it now either check the `GOLEM_CONFIG_PATH` env var or the default path (inst/golem-config.yml). `{golem}` no longer tries to guess non standard paths, and does a hard fail if the file doesn't exist, (2) the function no longer copy the `config` files from the skeleton if ever the files are not there (@ilyaZar, @LDSamson, #1178)
1437

1538
- `{golem}` functions used to rely on arguments that where either `wd`, `path`, `pkg` or `golem_wd`. This has now been standardized and all functions rely on `golem_wd` now (@ilyaZar, #845)
1639

40+
- `get_sysreqs()` has been removed; use `dockerfiler::get_sysreqs()` instead.
41+
42+
- `use_recommended_deps()` has been removed.
43+
44+
- `add_rstudioconnect_file()` has been removed; use `add_positconnect_file()` instead.
45+
1746
- Creating a `golem` doesn't call `set_here()` nor `usethis::create_project()` anymore. It used to be because we wanted to be able to use `here::here()`, but the function should be able to find its way based using `DESCRIPTION`. It gives a lighter implementation of golem projects creation as it doesn't mess up with where `here()` is anymore.
1847

1948
- The `add_*_files` and `use_*_files` now fail when:
20-
- The directory where the user tries to add the file doesn't exist. `{golem}` used to try to create the directory but that's not the function job — use\_\*\_file functions should only be there to add file (Singe responsabily )
49+
50+
- The directory where the user tries to add the file doesn't exist. `{golem}` used to try to create the directory but that's not the function job — use\_\*\_file functions should only be there to add file (Single responsibility)
2151
- The file that the user tries to create already exists
2252

2353
- Creating a golem with `create_golem(overwrite = TRUE)` will now **delete the old folder** and replace with the golem skeleton.
2454

55+
- `add_js_input_binding()` and `add_js_output_binding()` generate JS files with a new naming scheme: `<name>-input.js` / `<name>-output.js` (previously `input-<name>.js` / `output-<name>.js`). Manually rename or delete any old binding files (@ilyaZar, #868, #869)
56+
57+
- The default `events` argument of `add_js_input_binding()` has changed from `list(name = "click", rate_policy = FALSE)` to `list(name = c("change", "input"), rate_policy = c(FALSE, FALSE))` to produce a functional input binding out of the box (@ilyaZar, #868)
58+
2559
## User visible change
2660

2761
- `run_dev()` only prints one message (#1191 / @howardbaik)
2862

63+
## Soft deprecated
64+
65+
- `browser_button()` is now soft deprecated (#1155)
66+
67+
- `add_dockerfile()`, `add_dockerfile_shinyproxy()`, and
68+
`add_dockerfile_heroku()` are now explicitly soft deprecated; use the
69+
corresponding `add_dockerfile_with_renv_*()` functions.
70+
2971
## Bug fix
3072

3173
- Removing the comments on golem creation didn't work fully, this has been fixed.
@@ -36,6 +78,8 @@
3678

3779
## Internal changes
3880

81+
- Added internal `cli_progress_bar()`, `cli_progress_update()`, `cli_progress_done()` wrappers and `cat_start_unzip()` / `cat_unzipped()` helpers (@ilyaZar, #1234)
82+
3983
- `{golem}` now embarks a `claude.md` file and a series of skills
4084

4185
- Full refactoring of the `add_*_files` and `use_*_files` functions that now all share the same behavior

0 commit comments

Comments
 (0)