Skip to content

Commit

Permalink
Merge pull request #343 from ThinkR-open/dev
Browse files Browse the repository at this point in the history
golem 0.2.0 — CRAN release candidate
  • Loading branch information
ColinFay authored Mar 4, 2020
2 parents ecab7aa + 5fb1715 commit 893d311
Show file tree
Hide file tree
Showing 108 changed files with 3,703 additions and 1,196 deletions.
2 changes: 2 additions & 0 deletions .Rbuildignore
Original file line number Diff line number Diff line change
Expand Up @@ -18,3 +18,5 @@
^CRAN-RELEASE$
^appveyor\.yml$
^CONTRIBUTING\.md$
^doc$
^Meta$
14 changes: 14 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# Set the default behavior, in case people don't have core.autocrlf set.
* text=auto

# Declare files that will always have CRLF line endings on checkout.
*.Rd text eol=lf
*.R text eol=lf
*.Rmd text eol=lf
*.md text eol=lf
NAMESPACE text eol=lf
DESCRIPTION text eol=lf

# Denote all files that are truly binary and should not be modified.
*.png binary
*.jpg binary
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,5 @@ inst/rstudio/.DS_Store
.Rproj.user
.Rhistory
.RData
doc
Meta
30 changes: 18 additions & 12 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Package: golem
Title: A Framework for Robust Shiny Applications
Version: 0.1.0.9001
Version: 0.2.0
Authors@R:
c(person(given = "Vincent",
family = "Guyader",
Expand All @@ -22,6 +22,10 @@ Authors@R:
role = "aut",
email = "[email protected]",
comment = c(ORCID = "0000-0002-4816-4624")),
person(given = "Novica",
family = "Nakov",
role = "ctb",
email = "[email protected]"),
person(given = "ThinkR",
role = "cph"))
Description: An opinionated framework for building a
Expand All @@ -36,40 +40,42 @@ Depends:
Imports:
attempt (>= 0.3.0),
cli,
config,
crayon,
desc,
dockerfiler,
DT,
glue,
fs,
here,
htmltools,
jsonlite,
pkgload,
processx,
remotes,
rlang,
roxygen2,
rsconnect,
rstudioapi,
shiny,
stats,
stringr,
testthat,
tools,
usethis,
utils,
yesno
yaml
Suggests:
spelling,
covr,
devtools,
glue,
knitr,
pkgbuild,
pkgdown,
purrr,
rcmdcheck,
rmarkdown,
rsconnect,
spelling,
stringr,
withr
VignetteBuilder:
knitr
Encoding: UTF-8
Language: en-US
LazyData: true
Roxygen: list(markdown = TRUE)
RoxygenNote: 6.1.1
Language: en-US
RoxygenNote: 7.0.2
38 changes: 38 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
FROM rocker/r-ver:3.5.1
RUN echo "options(repos = c(CRAN = 'https://cran.rstudio.com/'), download.file.method = 'libcurl')" >> /usr/local/lib/R/etc/Rprofile.site
RUN R -e 'install.packages("remotes")'
RUN R -e 'remotes::install_github("r-lib/remotes", ref = "97bbf81")'
RUN Rscript -e 'remotes::install_version("attempt", version = "0.3.0")'
RUN Rscript -e 'remotes::install_version("cli", version = "1.1.0")'
RUN Rscript -e 'remotes::install_version("crayon", version = "1.3.4")'
RUN Rscript -e 'remotes::install_version("dockerfiler", version = "0.1.3")'
RUN Rscript -e 'remotes::install_version("glue", version = "1.3.1")'
RUN Rscript -e 'remotes::install_version("htmltools", version = "0.4.0")'
RUN Rscript -e 'remotes::install_version("jsonlite", version = "1.6")'
RUN Rscript -e 'remotes::install_version("magrittr", version = "1.5")'
RUN Rscript -e 'remotes::install_version("pkgload", version = "1.0.2")'
RUN Rscript -e 'remotes::install_version("remotes", version = "2.1.0")'
RUN Rscript -e 'remotes::install_version("rlang", version = "0.4.0")'
RUN Rscript -e 'remotes::install_version("roxygen2", version = "6.1.1")'
RUN Rscript -e 'remotes::install_version("rsconnect", version = "0.8.15")'
RUN Rscript -e 'remotes::install_version("rstudioapi", version = "0.10")'
RUN Rscript -e 'remotes::install_version("shiny", version = "1.4.0")'
RUN Rscript -e 'remotes::install_version("testthat", version = "2.2.1")'
RUN Rscript -e 'remotes::install_version("usethis", version = "1.5.1")'
RUN Rscript -e 'remotes::install_version("yesno", version = "0.1.0")'
RUN Rscript -e 'remotes::install_version("purrr", version = "0.3.3")'
RUN Rscript -e 'remotes::install_version("covr", version = "3.3.2")'
RUN Rscript -e 'remotes::install_version("devtools", version = "2.2.1")'
RUN Rscript -e 'remotes::install_version("DT", version = "0.9")'
RUN Rscript -e 'remotes::install_version("knitr", version = "1.25")'
RUN Rscript -e 'remotes::install_version("pkgdown", version = "1.4.1")'
RUN Rscript -e 'remotes::install_version("rcmdcheck", version = "1.3.3")'
RUN Rscript -e 'remotes::install_version("rmarkdown", version = "1.16")'
RUN Rscript -e 'remotes::install_version("spelling", version = "2.1")'
RUN Rscript -e 'remotes::install_version("stringr", version = "1.4.0")'
RUN Rscript -e 'remotes::install_version("withr", version = "2.1.2")'
RUN Rscript -e 'remotes::install_github("r-lib/desc@42b9578f374bf685610b1efb05315927ae236d5b")'
RUN Rscript -e 'remotes::install_github("rstudio/packrat@c0a67564df0bff16c952117050f510f2c8eace0a")'
COPY golem_*.tar.gz /app.tar.gz
RUN R -e 'remotes::install_local("/app.tar.gz")'
CMD R -e "options('shiny.port'=$PORT,shiny.host='0.0.0.0');golem::run_app()"
47 changes: 42 additions & 5 deletions NAMESPACE
Original file line number Diff line number Diff line change
Expand Up @@ -9,15 +9,18 @@ export(add_fct)
export(add_js_file)
export(add_js_handler)
export(add_module)
export(add_resource_path)
export(add_rstudioconnect_file)
export(add_shinyappsio_file)
export(add_shinyserver_file)
export(add_ui_server_files)
export(add_utils)
export(amend_golem_config)
export(app_dev)
export(app_prod)
export(browser_button)
export(browser_dev)
export(bundle_resources)
export(cat_dev)
export(create_golem)
export(detach_all_attached)
Expand All @@ -27,16 +30,22 @@ export(expect_shinytag)
export(expect_shinytaglist)
export(favicon)
export(fill_desc)
export(get_dependencies)
export(get_golem_name)
export(get_golem_options)
export(get_golem_version)
export(get_golem_wd)
export(get_sysreqs)
export(invoke_js)
export(make_dev)
export(message_dev)
export(print_dev)
export(remove_favicon)
export(set_golem_name)
export(set_golem_options)
export(set_golem_version)
export(set_golem_wd)
export(use_external_css_file)
export(use_external_js_file)
export(use_favicon)
export(use_recommended_deps)
export(use_recommended_tests)
Expand All @@ -45,33 +54,61 @@ export(use_utils_ui)
export(warning_dev)
export(with_golem_options)
importFrom(attempt,attempt)
importFrom(attempt,is_try_error)
importFrom(attempt,stop_if)
importFrom(attempt,stop_if_not)
importFrom(attempt,without_warning)
importFrom(cli,cat_bullet)
importFrom(cli,cat_line)
importFrom(cli,cat_rule)
importFrom(config,get)
importFrom(desc,desc_get_deps)
importFrom(desc,description)
importFrom(glue,glue)
importFrom(htmltools,includeScript)
importFrom(dockerfiler,Dockerfile)
importFrom(fs,dir_create)
importFrom(fs,dir_exists)
importFrom(fs,file_copy)
importFrom(fs,file_create)
importFrom(fs,file_delete)
importFrom(fs,file_exists)
importFrom(fs,file_move)
importFrom(fs,file_temp)
importFrom(fs,path)
importFrom(fs,path_abs)
importFrom(fs,path_file)
importFrom(htmltools,htmlDependency)
importFrom(htmltools,save_html)
importFrom(htmltools,tags)
importFrom(jsonlite,fromJSON)
importFrom(pkgload,load_all)
importFrom(pkgload,pkg_name)
importFrom(pkgload,pkg_path)
importFrom(remotes,dev_package_deps)
importFrom(remotes,package_deps)
importFrom(rlang,enquo)
importFrom(roxygen2,roxygenise)
importFrom(rstudioapi,getSourceEditorContext)
importFrom(rstudioapi,isAvailable)
importFrom(rstudioapi,modifyRange)
importFrom(rstudioapi,navigateToFile)
importFrom(rstudioapi,openProject)
importFrom(shiny,addResourcePath)
importFrom(shiny,getShinyOption)
importFrom(stats,setNames)
importFrom(shiny,includeScript)
importFrom(testthat,expect)
importFrom(testthat,expect_equal)
importFrom(testthat,quasi_label)
importFrom(usethis,proj_set)
importFrom(usethis,use_build_ignore)
importFrom(usethis,use_package)
importFrom(usethis,use_testthat)
importFrom(utils,capture.output)
importFrom(utils,download.file)
importFrom(utils,file.edit)
importFrom(utils,getFromNamespace)
importFrom(utils,installed.packages)
importFrom(utils,menu)
importFrom(utils,packageVersion)
importFrom(utils,sessionInfo)
importFrom(yesno,yesno)
importFrom(yaml,read_yaml)
importFrom(yaml,write_yaml)
77 changes: 76 additions & 1 deletion NEWS.md
Original file line number Diff line number Diff line change
@@ -1,19 +1,74 @@
> Notes: the # between parenthesis referes to the related issue on GitHub, and the @ refers to an external contributor solving this issue.
# golem 0.1.9000+

## New functions

+ `add_dockerfile()` was completely refactored. It now starts from r-ver, uses explicit package versions from you local machine, and tries to set as much System Requirements as possible by using `{sysreq}`, and parses and installs the Remotes tag from the DESCRIPTION (#189, #175)

+ `add_dockerfile()` allow now to directly use the source of the package by mounting the source folder in the container and running `remotes::install_local()`

+ `add_dockerfile()` now builds the tar.gz (#273)

+ `add_fct` and `add_utils` add new files in your R folder that can hold utils and functions (#123).

+ We switched from `shiny::addResourcePath()` to `golem::add_resource_path()`, which doesn't fail if the folder is empty (#223).

+ New JavaScript functions to use alert, prompt and confirm (#108, @zwycl)

+ `use_external_js_file` and `use_external_css_file` are designed to download .js and .css file off the web to the appropriate directory (#130, @zwycl)


## New features

+ `{golem}` now comes with an internal config file. Please refer to the `config` Vignette for more information.

+ `bundle_resources()` comes with every new app and bundles all the css and js files you put inside the `inst/app/www` folder, by matchine the file extension.

+ There is now an `app_sys()` function, which is a wrapper around `system.file(..., package = "myapp")` (#207, @novica)

+ `document_and_reload()` now stops when it fails, and returns an explicit failure message (#157)

+ You can now create a golem without any comment (#171, @ArthurData)

+ The default `app_ui()` now has a `request` parameter, to natively handle bookmarking.

+ `document_and_reload()` now stops when it fails, and returns an explicit failure message (#157). It also uses `get_golem_wd()` as a default path, to be consistent with the rest of `{golem}` (#219, @j450h1)

+ `add_module` now allows to create and `fct_` and an `utils_` file (#154, @novica)

+ `golem::detach_all_attached()` is now silent (#186, @annakau)

+ There is now a series of addins for going to a specific golem file (#212, @novica), and also to wrap a selected text into `ns()` (#143, @kokbent)

+ Creation of a golem project is now a little bit more talkative (#63, @novica)

+ golem apps now have a title tag in the header by default, (#172, @novica)

+ The `rsconnect` folder is now added to `.Rbuildignore` (#244)

+ `devtools::test()` in 03_deploy.R is now `devtools::check()`

+ modules bow have a placeholder for content

+ Dev scripts have been rewritten and rerordered a litte bit

## Breaking changes

+ `invoke_js()` now takes a list of elements to send to JS (through `...`) instead of a vector (#155, @zwycl)

+ `get_dependencies` was removed from this package, please use `desc::desc_get_deps()` instead (#251)

+ `{golem}` now uses `here::here()` to determine the default working directory (#287)

+ Modules used to be exported by default. You now have to specify it when creating the modules (#144)

+ `run_app()` is no longer explicitely namespaced in the run_dev script (#267)

+ JavaScript files now default to having `$(document).ready()` (#227)

+ Every filesystem manipulation is now done with `{fs}`. That should be pretty transparent for most users but please open an issue if it causes problem (#285)

## Bug fix

+ The Dockerfile is now correctly added to .Rbuildignore (#81)
Expand All @@ -24,8 +79,26 @@

+ spellcheck in files (@privefl)

+ Message to link to `golem_add_external_resources()` is now conditional to R being in a golem project (#167, @novica)

+ Better error on missing name in add_*, (#120, @novica)

+ When adding file, the extension is now ignored if provided by the user (#231)

+ The dots R/run_app.R are now documented by default (#243)

+ Bug fix of the pkgdown website (#180)

+ `{golem}` now correctly handles command line creation of projet inside the current directory (#248)

+ The test are now more robust when it comes to random name generation (#281)

## Internal changes

+ We no longer depend on `{stringr}` (#201, @TomerPacific)

+ get_golem_wd() is now used everywhere in `{golem}` (#237, @felixgolcher)

# golem 0.1.0 - CRAN release candidate, v2

## New Functions
Expand All @@ -42,11 +115,13 @@

+ The `installed.packages()` function is no longer used.

+ Every filesystem manipulation is now done with `{fs}` (#285)

# golem 0.0.1.9999 - CRAN release candidate

## Changes in the way run_app and deploy files are build

+ There is now a unique framework for run_app, that allows to deploy anywhere and can accept arguments. These arguments can then be retrieved with `get_golem_options()`. #
+ There is now a unique framework for run_app, that allows to deploy anywhere and can accept arguments. These arguments can then be retrieved with `get_golem_options()`.

> See https://rtask.thinkr.fr/blog/shinyapp-runapp-shinyappdir-difference/
Expand Down
Loading

0 comments on commit 893d311

Please sign in to comment.