-
Notifications
You must be signed in to change notification settings - Fork 24
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #253 from Appsilon/develop
Release v1.0.0
- Loading branch information
Showing
61 changed files
with
552 additions
and
403 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,6 +4,6 @@ | |
^\.gitignore$ | ||
^\.lintr$ | ||
^\.Rproj\.user$ | ||
^\.whitesource$ | ||
^pkgdown$ | ||
^README\.md$ | ||
^vignettes$ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
Package: rhino | ||
Title: A Framework for Enterprise Shiny Applications | ||
Version: 0.8.0 | ||
Version: 1.0.0 | ||
Authors@R: | ||
c( | ||
person("Kamil", "Zyla", role = c("aut", "cre"), email = "[email protected]"), | ||
|
@@ -16,12 +16,12 @@ License: LGPL-3 | |
Encoding: UTF-8 | ||
Roxygen: list(markdown = TRUE) | ||
RoxygenNote: 7.1.2 | ||
VignetteBuilder: knitr | ||
Depends: | ||
R (>= 2.10) | ||
Imports: | ||
box, | ||
cli, | ||
config, | ||
fs, | ||
glue, | ||
lintr (>= 2.0.0), | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -9,5 +9,6 @@ export(init) | |
export(lint_js) | ||
export(lint_r) | ||
export(lint_sass) | ||
export(log) | ||
export(test_e2e) | ||
export(test_r) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,20 +1,8 @@ | ||
create_module <- function() { | ||
rstudioapi::insertText(glue::trim(" | ||
box::use( | ||
shiny[moduleServer, NS] | ||
) | ||
#' @export | ||
ui <- function(id) { | ||
ns <- NS(id) | ||
} | ||
#' @export | ||
server <- function(id) { | ||
moduleServer(id, function(input, output, session) { | ||
read_addin <- function(...) { | ||
path <- fs::path_package("rhino", "rstudio", "addins", ...) | ||
readChar(path, file.info(path)$size) | ||
} | ||
|
||
}) | ||
}" | ||
)) | ||
addin_module <- function() { | ||
rstudioapi::insertText(read_addin("module.R")) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
#' Logging functions | ||
#' | ||
#' Convenient way to log messages at a desired severity level. | ||
#' | ||
#' The `log` object is a list of logging functions, in order of decreasing severity: | ||
#' 1. `fatal` | ||
#' 2. `error` | ||
#' 3. `warn` | ||
#' 4. `success` | ||
#' 5. `info` | ||
#' 6. `debug` | ||
#' 7. `trace` | ||
#' | ||
#' Rhino configures logging based on settings read from the `config.yml` file | ||
#' in the root of your project: | ||
#' 1. `rhino_log_level`: The minimum severity of messages to be logged. | ||
#' 2. `rhino_log_file`: The file to save logs to. If `NA`, standard error stream will be used. | ||
#' | ||
#' The default `config.yml` file uses `!expr Sys.getenv()` | ||
#' so that log level and file can also be configured | ||
#' by setting the `RHINO_LOG_LEVEL` and `RHINO_LOG_FILE` environment variables. | ||
#' | ||
#' The functions re-exported by the `log` object are aliases for `{logger}` functions. | ||
#' You can also import the package and use it directly to utilize its full capabilities. | ||
#' | ||
#' @examples | ||
#' \dontrun{ | ||
#' box::use(rhino[log]) | ||
#' | ||
#' # Messages can be formatted using glue syntax. | ||
#' name <- "Rhino" | ||
#' log$warn("Hello {name}!") | ||
#' log$info("{1:3} + {1:3} = {2 * (1:3)}") | ||
#' } | ||
#' @export | ||
log <- list( | ||
fatal = logger::log_fatal, | ||
error = logger::log_error, | ||
warn = logger::log_warn, | ||
success = logger::log_success, | ||
info = logger::log_info, | ||
debug = logger::log_debug, | ||
trace = logger::log_trace | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.