-
Notifications
You must be signed in to change notification settings - Fork 9
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
Update .rs.api.versionInfo()
#531
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,20 +1,34 @@ | ||
#' @export | ||
.rs.api.versionInfo <- function() { | ||
# comments are what rstudioapi actually does | ||
# https://github.com/rstudio/rstudio/blob/bb729e14867f6f95e26600d8b38e4551402cf7de/src/cpp/r/R/Api.R#L135-L145 | ||
# info <- list() | ||
|
||
current_year <- format(Sys.Date(), "%Y") | ||
positron_citation <- | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. See here for what RStudio has for a citation: https://github.com/rstudio/rstudio/blob/main/src/cpp/session/resources/CITATION.in There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Minor, do you think RStudio should have used |
||
utils::bibentry( | ||
"Manual", | ||
title = "Positron: A next generation data science IDE", | ||
author = utils::person("Posit team"), | ||
organization = "Posit Software, PBC", | ||
address = "Boston, MA", | ||
year = current_year, | ||
url = "https://www.posit.co/", | ||
textVersion = | ||
paste( | ||
paste0("Posit team (", current_year, "). "), | ||
"Positron: A next generation data science IDE. ", | ||
"Posit Software, PBC, Boston, MA. ", | ||
"URL https://www.posit.co/.", | ||
sep = "" | ||
), | ||
mheader = "To cite Positron in publications use:", | ||
mfooter = "" | ||
) | ||
class(positron_citation) <- c("citation", "bibentry") | ||
|
||
list( | ||
# info$citation <- .Call("rs_rstudioCitation", PACKAGE = "(embedding)") | ||
citation = NULL, | ||
# info$mode <- .Call("rs_rstudioProgramMode", PACKAGE = "(embedding)") | ||
mode = "desktop", | ||
# info$edition <- .Call("rs_rstudioEdition", PACKAGE = "(embedding)") | ||
# info$version <- .Call("rs_rstudioVersion", PACKAGE = "(embedding)") | ||
# info$version <- package_version(info$version) | ||
version = package_version("2023.3"), | ||
# info$long_version <- .Call("rs_rstudioLongVersion", PACKAGE = "(embedding)") | ||
long_version = "2023.03.0" | ||
# info$release_name <- .Call("rs_rstudioReleaseName", PACKAGE = "(embedding)") | ||
citation = positron_citation, | ||
mode = Sys.getenv("POSITRON_MODE"), | ||
version = package_version(Sys.getenv("POSITRON_VERSION")), | ||
long_version = Sys.getenv("POSITRON_LONG_VERSION"), | ||
ark_version = .ps.ark.version() | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I thought it might be nice to include the ark version here. Thoughts? |
||
) | ||
# info | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
TIL!