diff --git a/.github/workflows/R-CMD-check.yaml b/.github/workflows/R-CMD-check.yaml index bccabb40..e5571a7f 100644 --- a/.github/workflows/R-CMD-check.yaml +++ b/.github/workflows/R-CMD-check.yaml @@ -5,24 +5,36 @@ on: branches: [main, master, devel] pull_request: branches: [main, master, devel] + schedule: + # (see https://crontab.guru) + - cron: "30 3 * */2 TUE" + workflow_dispatch: name: R-CMD-check +concurrency: + group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} + cancel-in-progress: true + jobs: R-CMD-check: runs-on: ${{ matrix.config.os }} + concurrency: + group: > + ${{ github.workflow }}-${{ matrix.config.os }}-${{ matrix.config.r }})- + ${{ github.event_name != 'pull_request' || github.run_id }} + cancel-in-progress: true + name: ${{ matrix.config.os }} (R-${{ matrix.config.r }}) strategy: fail-fast: false matrix: config: - - {os: macOS-latest, r: 'release'} + - {os: macos-latest, r: 'release'} - {os: windows-latest, r: 'release'} - # - {os: ubuntu-latest, r: 'devel', http-user-agent: 'release'} - - {os: ubuntu-latest, r: 'release'} - # - {os: ubuntu-latest, r: 'oldrel-1'} + - {os: ubuntu-latest, r: 'release'} env: R_KEEP_PKG_SOURCE: yes @@ -36,11 +48,9 @@ jobs: - uses: r-lib/actions/setup-r@v2 with: r-version: ${{ matrix.config.r }} - http-user-agent: ${{ matrix.config.http-user-agent }} use-public-rspm: true extra-repositories: "https://mokymai.github.io/download/" - - uses: r-lib/actions/setup-r-dependencies@v2 with: extra-packages: any::rcmdcheck diff --git a/.github/workflows/drat--publish-package.yaml b/.github/workflows/drat--publish-package.yaml index e928d264..b8c9816a 100644 --- a/.github/workflows/drat--publish-package.yaml +++ b/.github/workflows/drat--publish-package.yaml @@ -1,9 +1,9 @@ on: push: - branches: - - master + branches: [master, main] + workflow_dispatch: -name: Publish package +name: Publish package (drat) jobs: drat: @@ -24,13 +24,13 @@ jobs: env: R_REMOTES_NO_ERRORS_FROM_WARNINGS: true + GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }} SOURCE_REPO: ${{ github.repository }} DEST_REPO: mokymai/download TMP_DIR: tmp_dir - CACHE_VERSION: 1 steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - name: Info run: | @@ -39,33 +39,20 @@ jobs: - uses: r-lib/actions/setup-r@v2 with: r-version: ${{ matrix.config.r }} + use-public-rspm: true + extra-repositories: "https://mokymai.github.io/download/" - - name: Query dependencies - run: | - install.packages('remotes') - saveRDS(remotes::dev_package_deps(dependencies = TRUE), ".github/depends.Rds", version = 2) - writeLines(sprintf("R-%i.%i", getRversion()$major, getRversion()$minor), ".github/R-version") - shell: Rscript {0} - - - name: Restore R package cache - # if: runner.os != 'Windows' - uses: actions/cache@v2 + - uses: r-lib/actions/setup-r-dependencies@v2 with: - path: ${{ env.R_LIBS_USER }} - key: ${{ runner.os }}-${{ hashFiles('.github/R-version') }}-${CACHE_VERSION}-${{ hashFiles('.github/depends.Rds') }} - restore-keys: ${{ runner.os }}-${{ hashFiles('.github/R-version') }}-${CACHE_VERSION}- - - - name: Install dependencies - shell: Rscript {0} - run: | - remotes::install_cran(c("roxygen2", "devtools", "drat")) - remotes::install_deps(dependencies = TRUE) + cache-version: 1 + extra-packages: | + roxygen2 + devtools + drat - name: Roxygenize shell: Rscript {0} - run: | - roxygen2::roxygenize() - + run: roxygen2::roxygenize() - name: Build source package if: runner.os == 'Windows' && matrix.config.r == 'release' @@ -91,7 +78,7 @@ jobs: TOKEN: ${{ secrets.DEPLOY_DRAT_TOKEN }} - name: Git clone DEST_REPO - uses: actions/checkout@v2 + uses: actions/checkout@v3 with: repository: ${{ env.DEST_REPO }} # 'mokymai/download' ref: 'master' diff --git a/.github/workflows/pkgdown.yaml b/.github/workflows/pkgdown.yaml index bd4c72ee..efe23d37 100644 --- a/.github/workflows/pkgdown.yaml +++ b/.github/workflows/pkgdown.yaml @@ -1,11 +1,13 @@ +# Workflow derived from https://github.com/r-lib/actions/tree/v2/examples +# Need help debugging build failures? Start at https://github.com/r-lib/actions#where-to-find-help on: push: - branches: [main, master, devel] + branches: [main, master] release: types: [published] workflow_dispatch: -name: Update website +name: Update website (pkgdown) jobs: pkgdown: @@ -15,7 +17,8 @@ jobs: group: pkgdown-${{ github.event_name != 'pull_request' || github.run_id }} env: GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }} - + permissions: + contents: write steps: - uses: actions/checkout@v3 @@ -23,8 +26,8 @@ jobs: - uses: r-lib/actions/setup-r@v2 with: + r-version: "release" use-public-rspm: true - r-version: 'release' extra-repositories: "https://mokymai.github.io/download/" - uses: r-lib/actions/setup-r-dependencies@v2 @@ -62,7 +65,7 @@ jobs: - name: Deploy to GitHub pages 🚀 if: github.event_name != 'pull_request' - uses: JamesIves/github-pages-deploy-action@4.1.4 + uses: JamesIves/github-pages-deploy-action@v4 with: clean: false branch: gh-pages diff --git a/DESCRIPTION b/DESCRIPTION index 7736a959..aec6b6f9 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,8 +1,8 @@ Package: bio Type: Package Title: Resources Manager for BS-2023 -Version: 0.2.2.1 -Date: 2023-04-23 +Version: 0.2.2.2 +Date: 2023-08-08 Authors@R: person("Vilmantas", "Gegzna", role = c("aut", "cre"), comment = c(ORCID = "0000-0002-9500-5167"), @@ -22,7 +22,7 @@ RoxygenNote: 7.2.3 Additional_repositories: https://mokymai.github.io/download/ Imports: - backup.tools (>= 0.0.1), + backup.tools, checkmate, clipr, crayon, @@ -37,12 +37,10 @@ Imports: purrr, quarto, readr (>= 2.0.0), - rematch2, remotes, rlang, rstudioapi (>= 0.13), - snippets (>= 0.0.9), - stringi, + snippets, stringr, styler, tibble (>= 3.1.4), diff --git a/NAMESPACE b/NAMESPACE index f41cc464..8304f50c 100644 --- a/NAMESPACE +++ b/NAMESPACE @@ -8,8 +8,6 @@ export(check_updates_pkg_bio) export(check_updates_rcmdr_biostat) export(check_user_info) export(compare_version) -export(emokymai_browse_assingment) -export(emokymai_submit_assingment) export(get_last_pkgs_installation_status) export(get_os_type) export(get_path_desktop) @@ -46,6 +44,7 @@ export(open_rstudio_snippets_dir) export(open_rstudio_system_dictionaries_dir) export(open_rstudio_user_dictionaries_dir) export(open_user_proj_list) +export(pkg_list_archived_versions) export(read_projects) export(restart_r) export(restart_rstudio) @@ -53,16 +52,10 @@ export(rstudio_compare_user_settings) export(rstudio_delete_spellcheck_dictionaries) export(rstudio_download_spellcheck_dictionaries) export(rstudio_install_spellcheck_dictionaries) -export(rstudio_install_spellcheck_dictionary_lt) export(rstudio_reload_ui) export(rstudio_reset_keybindings) export(rstudio_reset_user_settings) export(rstudio_restart_r) -export(to_ascii_lower) -export(u_check_filename) -export(u_create_filename) -export(u_parse_filename) -export(u_prepare_assignment_dc) export(update_pkg_bio) export(update_pkg_rcmdr_biostat) export(update_pkg_snippets) @@ -82,6 +75,7 @@ importFrom(magrittr,"%>%") importFrom(rlang,.data) importFrom(snippets,get_path_rstudio_snippets_dir) importFrom(snippets,open_rstudio_snippets_dir) +importFrom(stats,na.omit) importFrom(stats,setNames) importFrom(usethis,ui_code) importFrom(usethis,ui_done) diff --git a/R/dictionaries.R b/R/dictionaries.R index 1edbc8e9..17030bc7 100644 --- a/R/dictionaries.R +++ b/R/dictionaries.R @@ -77,8 +77,6 @@ open_rstudio_internal_dictionaries_dir <- function() { #' @description #' - `rstudio_download_spellcheck_dictionaries()` #' downloads and updates RStudio (system) spellchecking dictionaries. -#' - `rstudio_download_spellcheck_dictionaries_lt()` -#' installs improved Lithuanian spellchecking dictionary. #' - `rstudio_delete_spellcheck_dictionaries()` #' deletes RStudio (system) spellchecking dictionaries. #' @@ -92,7 +90,6 @@ open_rstudio_internal_dictionaries_dir <- function() { #' \dontrun{\donttest{ #' rstudio_delete_spellcheck_dictionaries() #' rstudio_download_spellcheck_dictionaries() -#' rstudio_install_spellcheck_dictionary_lt() #' }} rstudio_install_spellcheck_dictionaries <- function(secure = TRUE) { @@ -109,10 +106,7 @@ rstudio_install_spellcheck_dictionaries <- function(secure = TRUE) { rstudio_download_spellcheck_dictionaries <- rstudio_install_spellcheck_dictionaries # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -#' @name spelling -#' @export -#' @concept r and rstudio settings -#' @concept dictionaries + rstudio_install_spellcheck_dictionary_lt <- function() { tryCatch({ diff --git a/R/helpers.R b/R/helpers.R index 368c439d..4902440e 100644 --- a/R/helpers.R +++ b/R/helpers.R @@ -28,8 +28,8 @@ get_upgrade_str <- function(upgrade) { # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ui_msg_restart_rstudio <- function() { usethis::ui_todo(paste0( - "To take effect, {underline('RStudio')} should be ", - "{underline('closed and reopened')}." + "To apply all changes, {underline('close and reopen')} ", + "{underline('RStudio')}." )) } # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ diff --git a/R/packages--check.R b/R/packages--check.R index 51967b3b..44edaa86 100644 --- a/R/packages--check.R +++ b/R/packages--check.R @@ -339,6 +339,48 @@ get_pkgs_cran_details <- function(repos = NULL) { cran_all } +#' Get previous package versions available on CRAN +#' +#' Function to scrape the CRAN website and retrieve archived (old) package versions +#' +#' @param package (character) +#' Package name. +#' +#' @return Vector with version numbers (the current version is not present). +#' @export +#' +#' @importFrom stats na.omit +#' +#' @examples +#' pkg_list_archived_versions("ggplot2") +#' +#' pkg_list_archived_versions("none") +pkg_list_archived_versions <- function(package) { + + # Base URL of archived packages on CRAN + url <- "https://cran.r-project.org/src/contrib/Archive/" + + # Create the complete URL for the package + package_url <- paste0(url, package) + + # Extract the webpage table rows containing the package versions + rows <- try( + suppressWarnings(readLines(package_url, warn = FALSE)), + silent = TRUE + ) + + if (inherits(rows, "try-error")) { + return(as.numeric_version(NULL)) + } + + # Extract the archived versions + rows |> + stringr::str_extract(stringr::str_glue("{package}_(.*?)[.]tar[.]gz"), 1) |> + na.omit() |> + as.numeric_version() |> + sort(decreasing = TRUE) +} + # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ #' Get Details About Non-CRAN Package Installation #' diff --git a/R/settings.R b/R/settings.R index 7863af59..507e10f9 100644 --- a/R/settings.R +++ b/R/settings.R @@ -45,7 +45,7 @@ restriction_status <- function(ignore_ip = getOption("bio.ignore_ip", FALSE), #' 1) Resets RStudio state and user preferences (incl. color scheme) #' 2) Clears function history, plot history, console, recent project list, etc. #' 3) Closes unnecessary windows -#' 4) Resets custom keybindings to "bio-default" +#' 4) Resets custom key bindings to "bio-default" #' 5) Resets R Markdown and R snippets to defaults in package "snippets" #' 6) Creates folder "~/R/darbinis" and starts using it as working directory #' when no project is used. diff --git a/R/u_task_names.R b/R/u_task_names.R deleted file mode 100644 index 1fe5632c..00000000 --- a/R/u_task_names.R +++ /dev/null @@ -1,361 +0,0 @@ -#' Transliterate to ASCII Lower-Case Symbol -#' -#' Transliterate all symbols in a string into lower-case ASCII symbols. -#' -#' -#' @param x A string or a character vector. -#' -#' @return A modified string or character vector. -#' -#' @export -#' -#' @examples -#' to_ascii_lower("AbD") -#' to_ascii_lower(c("AAA", "BbB")) -#' -to_ascii_lower <- function(x) { - x <- stringi::stri_trans_general(x, id = "Any-Latin;Greek-Latin;Latin-ASCII") - tolower(x) -} - -format_name <- function(x) { - x <- stringi::stri_trans_general(x, id = "Any-Latin;Greek-Latin;Latin-ASCII") - x <- tools::toTitleCase(x) - gsub(pattern = "\\s+", replacement = "-", x) -} - -decode_speciality <- function(code) { - dplyr::case_when( - code %in% c("bioche", "biochemija") ~ "biochemija" , - code %in% c("biofiz", "biofizika") ~ "biofizika" , - code %in% c("biolog", "biologija") ~ "biologija" , - code %in% c("geneti", "genet", "genetika") ~ "genetika" , - code %in% c("mikrob", "mikrobiologija") ~ "mikrobiologija" , - code %in% c("molbio", "molekuline") ~ "molekuline biologija" , - code %in% c("molbti") ~ "molekuline biotechnologija", - code %in% c("neurbf", "neurobiofizika") ~ "neurobiofizika" , - code %in% c("neurbl", "neurobiologija") ~ "neurobiologija" , - # stop("Unknown code = '", code, "'") - TRUE ~ paste0("(?) UNIDENTIFIED VALUE { ", code ," }") - ) -} - -encode_speciality <- function(specialybe) { - spec <- to_ascii_lower(specialybe) - - supported <- c("biochemija", "biofizika", "biologija", "genetika", - "mikrobiologija", "molekuline biologija", "molekuline biotechnologija", - "neurobiofizika", "neurobiologija") - - not_supported <- specialybe[!spec %in% supported] - if (length(not_supported) > 0) { - stop("Unsupported value of 'specialybe': ", paste(not_supported, sep = ",")) - } - - dplyr::case_when( - specialybe == "biochemija" ~ "bioche", - specialybe == "biofizika" ~ "biofiz", - specialybe == "biologija" ~ "biolog", - specialybe == "genetika" ~ "geneti", - specialybe == "mikrobiologija" ~ "mikrob", - specialybe == "molekuline biologija" ~ "molbio", - specialybe == "molekuline biotechnologija" ~ "molbti", - specialybe == "neurobiofizika" ~ "neurbf", - specialybe == "neurobiologija" ~ "neurbl", - TRUE ~ paste0("(?) UNKNOWN { ", specialybe ," }") - # TRUE ~ stop("Unknown value: specialybe = '", specialybe, "'") - ) -} - -#' Create Filename for Type U Task -#' -#' Create a name for a file or folder which should be submitted as a "U" task. -#' -#' @name u_task -#' -#' @param uzduoties_nr (integer) The number of U task. -#' @param varianto_nr (integer) The variant of the task. -#' Each student has a unique personal variant number. -#' @param specialybe (character) Name of study program. -#' @param pavarde (character) Family name (names). -#' @param vardas (character) Sure name (names). -#' @param patikslinimas (character) Additional information. -#' @param dokumento_formatas (character) File name extension. -#' -#' @param x (character) A file name to parse or to check if it's structure -#' is correct. -#' -#' @return -#' - `u_create_filename()` returns sting with formatted file name. -#' - `u_parse_filename()` returns data frame with details extracted from -#' the filename. -#' - `u_check_filename()` returns `TRUE` if the structure of file name is -#' correct and `FALSE` otherwise. -#' -#' @export -#' @examples -#' u_create_filename( -#' uzduoties_nr = 1, -#' varianto_nr = 000, -#' specialybe = "molekuline biologija", -#' pavarde = "Pavarde", -#' vardas = "Vardas Antras", -#' patikslinimas = "sertifikatas", -#' dokumento_formatas = "pdf" -#' ) -#' -#' u_create_filename( -#' uzduoties_nr = 10, -#' varianto_nr = 000, -#' specialybe = "molekuline biologija", -#' pavarde = "Pavarde", -#' vardas = "Vardas Antras" -#' ) -#' -#' x <- "U01-v000-[molbio]-[Pavarde]-[Vardas-Antras]-sertifikatas.pdf" -#' -#' u_check_filename("U01-v000-[molbio]-[Pavarde]-[Vardas-Antras]-sertifikatas.pdf") -#' u_parse_filename("U01-v000-[molbio]-[Pavarde]-[Vardas-Antras]-sertifikatas.pdf") -#' -#' u_check_filename("U03-v000-[molekuline]-[Pavarde]-[Vardas].zip") -#' u_parse_filename("U03-v000-[molekuline]-[Pavarde]-[Vardas].zip") -#' -#' u_check_filename("U03-v000-[biofiz]-[Pavarde]-[Vardas]") -#' u_parse_filename("U03-v000-[biofiz]-[Pavarde]-[Vardas]") -#' -#' # Incorrect family name: -#' u_parse_filename("U03-v000-[molekuline]-[Pavarde3]-[Vardas].zip") -u_create_filename <- function(uzduoties_nr, - varianto_nr, - specialybe, - pavarde, - vardas, - patikslinimas = "", - dokumento_formatas = NULL) { - checkmate::assert_int(uzduoties_nr) - checkmate::assert_int(varianto_nr) - checkmate::assert_string(specialybe) - checkmate::assert_string(pavarde) - checkmate::assert_string(vardas) - checkmate::assert_string(patikslinimas) - checkmate::assert_string(dokumento_formatas, null.ok = TRUE) - - task <- sprintf("%02i", uzduoties_nr) - vers <- sprintf("%03i", varianto_nr) - - pavarde <- format_name(pavarde) - vard <- format_name(vardas) - more <- to_ascii_lower(patikslinimas) - more <- if (more == "") "" else paste0("-", more) - - if (is.null(dokumento_formatas)) { - ext <- "" - } else { - ext <- paste0(".", to_ascii_lower(dokumento_formatas)) - } - - spec <- encode_speciality(specialybe) - - stringr::str_glue("U{task}-v{vers}-[{spec}]-[{pavarde}]-[{vard}]{more}{ext}") -} - -#' @rdname u_task -#' @export -u_parse_filename <- function(x) { - rematch2::re_match( - x, - paste0( - "(?U\\d{2})-v(?\\d{3})", - "-\\[(?[a-z]*?)\\]", - "-\\[(?[A-Za-z-]*?)\\]", - "-\\[(?[A-Za-z-]*?)\\]", - "(-(?[a-z]*?))?", - "([.](?[A-Za-z]*?))?$" - ) - ) %>% - { - purrr::quietly(tibble::as_tibble) - }(.name_repair = "unique") %>% - .$result %>% - dplyr::select(-...6, -...8, -.text, -.match) %>% - dplyr::mutate( - specialybe = decode_speciality(specialybe), - pavarde = stringr::str_replace_all(pavarde, "-", " "), - vardas = stringr::str_replace_all(vardas, "-", " "), - patikslinimas = - dplyr::if_else( - !tolower(patikslinimas) %in% c("", "sertifikatas", "konspektas"), - paste0("(?) UNIDENTIFIED VALUE { ", patikslinimas, " }"), - patikslinimas - ), - dokumento_formatas = - dplyr::case_when( - dokumento_formatas == "" ~ "{ FOLDER }", - tolower(dokumento_formatas) %in% c("pdf", "zip") ~ dokumento_formatas, - TRUE ~ paste0("(?) UNSUPPORTED EXTENSION { ", dokumento_formatas, " }") - ) - ) %>% - as.matrix() %>% - t() %>% - `colnames<-`("Reiksme") %>% - as.data.frame() %>% - tibble::rownames_to_column("Kategorija") %>% - dplyr::mutate(Kategorija = paste0(Kategorija, ": ")) -} - -#' @rdname u_task -#' @export -u_check_filename <- function(x) { - stringr::str_detect( - x, - paste0( - "U(\\d{2})-v(\\d{3})", # technical info - "-\\[[a-z]*?\\]-\\[([A-Za-z-]*?)\\]-\\[([A-Za-z-]*?)\\]", # user name info - "(-[a-z]*?)?([.][a-z]*?)?$" # additional info and extension - ) - ) -} - - - - -#' Prepare Files For Submission (DataCamp Task) -#' -#' The function creates a folder (e.g.,`U00-atsakymai-ikelimui`) and copies files -#' indicated in `sertifikatas` and `konspektas` to that folder. -#' The copied files are properly renamed. -#' If needed, the function opens the folder and assignment submission webpage. -#' -#' @param uzduoties_nr (integer) -#' @param varianto_nr (integer) -#' @param specialybe (string) -#' @param pavarde (string) -#' @param vardas (string) -#' @param sertifikatas (string) Path to PDF file -#' (certificate issued by DataCamp). -#' @param konspektas (string) Path to PDF file. -#' @param open_dir (`TRUE`|`FALSE`) Open the directory with submission files. -#' @param emokymai_id (integer) Open the directory with submission files. -#' -#' @export -#' -#' @examples -#' if (FALSE) { -#' u_prepare_assignment_dc( -#' uzduoties_nr = 1, -#' varianto_nr = 000, -#' specialybe = "molekuline biologija", -#' pavarde = "Pavarde", -#' vardas = "Vardas Antras", -#' sertifikatas = "pratybos/certificate.pdf", -#' konspektas = "pratybos/konspektas.pdf" -#' ) -#' } -u_prepare_assignment_dc <- function(uzduoties_nr, varianto_nr, specialybe, - pavarde, vardas, sertifikatas, konspektas, - open_dir = FALSE, emokymai_id = NULL) { - - # Check input - arguments <- - c( - "uzduoties_nr", - "varianto_nr", - "specialybe", - "pavarde", - "vardas", - "sertifikatas", - "konspektas" - ) - missing_args <- - c( - missing(uzduoties_nr), - missing(varianto_nr), - missing(specialybe), - missing(pavarde), - missing(vardas), - missing(sertifikatas), - missing(konspektas) - ) - - if (any(missing_args)) { - stop( - "The following arguments are missing: ", - paste(arguments[missing_args], collapse = ", ") - ) - } - - # Check files - if (!fs::file_exists(sertifikatas)) { - stop("The file ('sertifikatas') was not found: ", sertifikatas) - } - - if (!fs::file_exists(konspektas)) { - stop("The file ('konspektas') was not found: ", konspektas) - } - - # TODO: Check, if files are (valid) PDF - - - # Main code - f_name_s <- bio::u_create_filename( - uzduoties_nr = uzduoties_nr, - varianto_nr = varianto_nr, - specialybe = specialybe, - pavarde = pavarde, - vardas = vardas, - patikslinimas = "sertifikatas", - dokumento_formatas = "pdf" - ) - - f_name_k <- bio::u_create_filename( - uzduoties_nr = uzduoties_nr, - varianto_nr = varianto_nr, - specialybe = specialybe, - pavarde = pavarde, - vardas = vardas, - patikslinimas = "konspektas", - dokumento_formatas = "pdf" - ) - - # Open assignment submision webpage - if (!is.null(emokymai_id)) { - emokymai_submit_assingment(id = emokymai_id) - } - - # Create directory - n_dir <- sprintf("U%02d-atsakymai-ikelimui", uzduoties_nr) - fs::dir_create(n_dir) - if (isTRUE(open_dir)) { - browseURL(n_dir) - } - - # Copy and rename files - c( - fs::file_copy(sertifikatas, fs::path(n_dir, f_name_s), overwrite = TRUE), - fs::file_copy(konspektas, fs::path(n_dir, f_name_k), overwrite = TRUE) - ) -} - - - -#' Open Resource on Emokymai -#' -#' @name emokymai -#' @param id Resource ID. -#' -#' @export -emokymai_browse_assingment <- function(id) { - e_url <- paste0("https://emokymai.vu.lt/mod/assign/view.php?id=", id) - browseURL(e_url) -} - -#' @rdname emokymai -#' @export -emokymai_submit_assingment <- function(id) { - e_url <- paste0( - "https://emokymai.vu.lt/mod/assign/view.php?id=", id, - "&action=editsubmission" - ) - browseURL(e_url) -} - diff --git a/README.Rmd b/README.Rmd index e3fa896f..9f9849c7 100644 --- a/README.Rmd +++ b/README.Rmd @@ -26,20 +26,21 @@ Sys.setenv(R_REMOTES_NO_ERRORS_FROM_WARNINGS = "true") [![R-CMD-check](https://github.com/mokymai/bio/workflows/R-CMD-check/badge.svg)](https://github.com/mokymai/bio/actions) [![Updated-on](https://img.shields.io/badge/Updated%20on-`r gsub('-', '--', Sys.Date())`-yellowgreen.svg)](/commits/master) [![Lifecycle: experimental](https://img.shields.io/badge/lifecycle-experimental-orange.svg)](https://www.tidyverse.org/lifecycle/#experimental) +[![R-CMD-check](https://github.com/mokymai/bio/actions/workflows/R-CMD-check.yaml/badge.svg)](https://github.com/mokymai/bio/actions/workflows/R-CMD-check.yaml) -Convenience functions to facilitate installation and management of required resources for course units __*Biostatistics*__ (*BS-2023*) and __*Introduction to data analysis with R*__. +Convenience functions to facilitate installation and management of required resources for course unit __*Biostatistics*__ (*BS-2023*).

-This package is intended to be used with RStudio 2022.12.0 or newer
-and R 4.2.2 or newer.
+This package is intended to be used with RStudio 2022.06.0 or newer
+and R 4.3.1 or newer.
Functions may not work correctly with the previous versions of RStudio and R. @@ -108,17 +109,17 @@ Options: ```{r README-7a, eval=FALSE} bio::check_installed_programs() -## ✔ Program R (4.2.2) is installed (recommended >= 4.2.2). +## ✔ Program R (4.3.1) is installed (recommended >= 4.3.1). ## ✖ Program RStudio is not installed or is not running. -## ✔ Tool Quarto (1.2.313) is installed (recommended >= 1.2.313). +## ✔ Tool Quarto (1.4.268) is installed (recommended >= 1.3.336). ## ✔ Tool Rtools is installed. ``` ```{r README-7b, eval=FALSE} bio::check_installed_programs("all") -## ✔ Program R (4.2.2) is installed (recommended 4.2.2, available 4.2.2). -## ✔ Program RStudio (2022.7.0.548) is installed (recommended 2022.7.0, available 2022.7.1.554). -## ✔ Tool Quarto (1.2.313) is installed (recommended >= 1.2.313). +## ✔ Program R (4.3.1) is installed (recommended >= 4.2.2, available 4.3.1). +## ✔ Program RStudio (2023.6.1.524) is installed (recommended >= 2023.3.0, available 2023.6.1.524). +## ✔ Tool Quarto (1.4.268) is installed (recommended >= 1.3.336). ## ✔ Tool Rtools is installed. ## ✔ Program Git is installed. ## ✔ Program Meld is installed. diff --git a/README.md b/README.md index 7f04e031..7af67f5d 100644 --- a/README.md +++ b/README.md @@ -6,9 +6,9 @@ Package ***bio*** [![GitHub -version](https://img.shields.io/badge/GitHub-0.2.2.1-brightgreen.svg)](https://github.com/mokymai/bio) +version](https://img.shields.io/badge/GitHub-0.2.2.2-brightgreen.svg)](https://github.com/mokymai/bio) [![R-CMD-check](https://github.com/mokymai/bio/workflows/R-CMD-check/badge.svg)](https://github.com/mokymai/bio/actions) -[![Updated-on](https://img.shields.io/badge/Updated%20on-2023--04--23-yellowgreen.svg)](/commits/master) +[![Updated-on](https://img.shields.io/badge/Updated%20on-2023--08--08-yellowgreen.svg)](/commits/master) [![Lifecycle: experimental](https://img.shields.io/badge/lifecycle-experimental-orange.svg)](https://www.tidyverse.org/lifecycle/#experimental) @@ -16,12 +16,11 @@ experimental](https://img.shields.io/badge/lifecycle-experimental-orange.svg)](h Convenience functions to facilitate installation and management of -required resources for course units ***Biostatistics*** (*BS-2023*) and -***Introduction to data analysis with R***. +required resources for course unit ***Biostatistics*** (*BS-2023*).

This package is intended to be used -with RStudio 2022.12.0 or newer
and R 4.2.2 or +with RStudio 2022.06.0 or newer
and R 4.3.1 or newer.
Functions may not work correctly with the previous versions of RStudio and R.


@@ -90,17 +89,17 @@ Options: ``` r bio::check_installed_programs() -## ✔ Program R (4.2.2) is installed (recommended >= 4.2.2). +## ✔ Program R (4.3.1) is installed (recommended >= 4.3.1). ## ✖ Program RStudio is not installed or is not running. -## ✔ Tool Quarto (1.2.313) is installed (recommended >= 1.2.313). +## ✔ Tool Quarto (1.4.268) is installed (recommended >= 1.3.336). ## ✔ Tool Rtools is installed. ``` ``` r bio::check_installed_programs("all") -## ✔ Program R (4.2.2) is installed (recommended 4.2.2, available 4.2.2). -## ✔ Program RStudio (2022.7.0.548) is installed (recommended 2022.7.0, available 2022.7.1.554). -## ✔ Tool Quarto (1.2.313) is installed (recommended >= 1.2.313). +## ✔ Program R (4.3.1) is installed (recommended >= 4.2.2, available 4.3.1). +## ✔ Program RStudio (2023.6.1.524) is installed (recommended >= 2023.3.0, available 2023.6.1.524). +## ✔ Tool Quarto (1.4.268) is installed (recommended >= 1.3.336). ## ✔ Tool Rtools is installed. ## ✔ Program Git is installed. ## ✔ Program Meld is installed. diff --git a/inst/dictionaries/lt_LT.zip b/inst/dictionaries/lt_LT.zip deleted file mode 100644 index faa8fcaf..00000000 Binary files a/inst/dictionaries/lt_LT.zip and /dev/null differ diff --git a/inst/install-r/pkgs-required-version.txt b/inst/install-r/pkgs-required-version.txt index dcefc85c..e72e1056 100644 --- a/inst/install-r/pkgs-required-version.txt +++ b/inst/install-r/pkgs-required-version.txt @@ -1,6 +1,6 @@ --- title: "Minimal required versions of packages" -date: 2023-01-22 +date: 2023-08-08 notes: "" @@ -11,13 +11,13 @@ notes: "" package | required_version | ignore | notes_version addin.tools | 0.0.10 | FALSE | - addins.rmd | 0.0.14 | FALSE | - -addins.rs | 0.0.11 | FALSE | - +addins.rs | 0.0.12 | FALSE | - backup.tools | 0.0.1 | FALSE | - -bio | 0.2.0 | FALSE | - -BiocManager | 1.30.18 | FALSE | - +bio | 0.2.2 | FALSE | - +BiocManager | 1.30.20 | FALSE | - blogdown | 1.9 | FALSE | - bookdown | 0.32 | FALSE | - -broom | 1.0.0 | FALSE | - +broom | 1.0.4 | FALSE | - bslib | 0.4.0 | FALSE | - car | 3.1-0 | FALSE | Rcmdr chemCal | 0.2.3 | FALSE | - @@ -25,14 +25,14 @@ citr | 0.3.2 | TRUE | - correlation | 0.8.1 | FALSE | - cowplot | 1.1.1 | FALSE | - data.table | 1.14.2 | FALSE | - -DescTools | 0.99.45 | FALSE | - +DescTools | 0.99.48 | FALSE | - devtools | 2.4.4 | FALSE | - -dplyr | 1.0.10 | FALSE | - -DT | 0.23 | FALSE | - +dplyr | 1.1.2 | FALSE | - +DT | 0.28 | FALSE | - effects | 4.2-2 | FALSE | Rcmdr effectsize | 0.7.0 | FALSE | - effsize | 0.8.1 | FALSE | - -esquisse | 1.1.1 | FALSE | - +esquisse | 1.1.2 | FALSE | - factoextra | 1.0.7 | FALSE | - flextable | 0.7.2 | FALSE | - forcats | 1.0.0 | FALSE | - @@ -40,13 +40,13 @@ fs | 1.5.2 | FALSE | - ggforce | 0.4.1 | FALSE | - gghighlight | 0.4.0 | FALSE | - ggmosaic | 0.3.3 | FALSE | - -ggplot2 | 3.4.0 | FALSE | - -ggpubr | 0.5.0 | FALSE | - +ggplot2 | 3.4.2 | FALSE | - +ggpubr | 0.6.0 | FALSE | - ggstatsplot | 0.10. | FALSE | - ggtext | 0.1.1 | FALSE | - glue | 1.6.2 | FALSE | - gt | 0.8.0 | FALSE | - -gtsummary | 1.7.0 | FALSE | - +gtsummary | 1.7.2 | FALSE | - haven | 2.5.0 | FALSE | - hms | 1.1.1 | FALSE | - hunspell | 3.0.2 | FALSE | - @@ -56,7 +56,7 @@ jsonlite | 1.8.0 | FALSE | - knitr | 1.42 | FALSE | - LanguageToolR | 0.1.3 | FALSE | - latex2exp | 0.9.6 | FALSE | - -lm.beta | 1.6-2 | FALSE | - +lm.beta | 1.7-2 | FALSE | - magick | 2.7.3 | FALSE | - magrittr | 2.0.3 | FALSE | - mlr3 | 0.13.4 | FALSE | - @@ -66,13 +66,13 @@ multcomp | 1.4-19 | FALSE | Rcmdr officer | 0.4.3 | FALSE | - openxlsx | 4.2.5 | FALSE | - pander | 0.6.5 | FALSE | - -patchwork | 1.1.1 | FALSE | - +patchwork | 1.1.2 | FALSE | - pkgdown | 2.0.6 | FALSE | - plotly | 4.9.4.1 | FALSE | - purrr | 0.3.4 | FALSE | - qqplotr | 0.0.6 | FALSE | - quarto | 1.2 | FALSE | - -Rcmdr | 2.7-2 | FALSE | - +Rcmdr | 2.8-1 | FALSE | - RcmdrMisc | 2.7-2 | FALSE | - RcmdrPlugin.biostat | 0.0.70 | FALSE | - RcmdrPlugin.EZR.as.menu | 1.55 | FALSE | - @@ -85,7 +85,7 @@ rgl | 0.96.0 | FALSE | Rcmdr rlang | 1.0.4 | FALSE | - rmarkdown | 2.9 | FALSE | - roxygen2 | 7.2.1 | FALSE | - -rstatix | 0.7.0 | FALSE | - +rstatix | 0.7.2 | FALSE | - rvg | 0.2.5 | FALSE | - scales | 1.2.0 | FALSE | - sem | 3.1-15 | FALSE | Rcmdr diff --git a/inst/install-r/programs-required-version.txt b/inst/install-r/programs-required-version.txt index 3691be3d..144af624 100644 --- a/inst/install-r/programs-required-version.txt +++ b/inst/install-r/programs-required-version.txt @@ -1,6 +1,6 @@ --- title: "Minimal required versions of programs" -date: 2023-04-23 +date: 2023-07-28 notes: "" @@ -9,7 +9,7 @@ notes: "" --- # This text must be in line 10 ----------------------------------------------- program | required_version | ignore | notes_version -R | 4.2.2 | FALSE | -RStudio | 2023.03.0 | FALSE | For 32-bit systems v 1.1.463 -Quarto | 1.3.336 | FALSE | +R | 4.3.1 | FALSE | +RStudio | 2023.06.0 | FALSE | For 32-bit systems v 1.1.463 +Quarto | 1.4.268 | FALSE | diff --git a/inst/rs-settings/rstudio-prefs--bio-2.json b/inst/rs-settings/rstudio-prefs--bio-2.json new file mode 100644 index 00000000..217d7488 --- /dev/null +++ b/inst/rs-settings/rstudio-prefs--bio-2.json @@ -0,0 +1,110 @@ +{ + "allow_source_columns" : true, + "always_save_history" : true, + "ansi_console_mode" : "on", + "auto_append_newline" : true, + "auto_detect_indentation" : false, + "auto_discover_package_dependencies" : true, + "auto_expand_error_tracebacks" : false, + "auto_run_setup_chunk" : true, + "auto_save_idle_ms" : 1000, + "auto_save_on_blur" : true, + "auto_save_on_idle" : "backup", + "background_diagnostics" : true, + "background_diagnostics_delay_ms" : 2000, + "blinking_cursor" : true, + "check_arguments_to_r_function_calls" : true, + "check_for_updates" : true, + "check_unexpected_assignment_in_function_call": true, + "clean_before_install" : true, + "clean_texi2dvi_output" : true, + "cleanup_after_r_cmd_check" : true, + "code_completion" : "always", + "code_completion_characters" : 3, + "code_completion_delay" : 250, + "code_completion_other" : "always", + "command_palette_mru" : true, + "console_code_completion" : true, + "console_double_click_select" : true, + "console_line_length_limit" : 1000, + "console_max_lines" : 1000, + "continue_comments_on_newline" : true, + "data_viewer_max_cell_size" : 50, + "data_viewer_max_columns" : 50, + "default_encoding" : "UTF-8", + "default_project_location" : "~/R", + "diagnostics_in_r_function_calls" : true, + "diagnostics_on_save" : true, + "doc_outline_show" : "sections_only", + "document_author" : "Vardas Pavarde", + "document_load_lint_delay" : 5000, + "editor_keybindings" : "default", + "enable_snippets" : true, + "enable_text_drag" : true, + "execution_behavior" : "statement", + "focus_console_after_exec" : true, + "fold_style" : "begin-and-end", + "full_project_path_in_window_title" : false, + "git_diff_ignore_whitespace" : false, + "help_font_size_points" : 11.0, + "hide_console_on_chunk_execute" : true, + "highlight_code_chunks" : true, + "highlight_console_errors" : true, + "highlight_r_function_calls" : true, + "highlight_selected_line" : true, + "highlight_selected_word" : true, + "highlight_web_link" : true, + "initial_working_directory" : "~/R/darbinis", + "insert_matching" : true, + "insert_native_pipe_operator" : false, + "insert_native_pipe_operator" : true, + "insert_parens_after_function_completion" : true, + "insert_spaces_around_equals" : true, + "jobs_tab_visibility" : "shown", + "knit_working_dir" : "default", + "line_ending_conversion" : "native", + "load_workspace" : false, + "margin_column" : 80, + "new_proj_git_init" : true, + "pdf_previewer" : "rstudio", + "rainbow_parentheses" : true, + "real_time_spellchecking" : true, + "reindent_on_paste" : false, + "restore_last_project" : true, + "restore_source_document_cursor_position" : true, + "restore_source_documents" : true, + "rmd_auto_date" : true, + "rmd_chunk_output_inline" : true, + "save_before_sourcing" : true, + "save_files_before_build" : true, + "save_workspace" : "never", + "show_diagnostics_other" : true, + "show_doc_outline_rmd" : false, + "show_help_tooltip_on_idle" : true, + "show_hidden_files" : true, + "show_indent_guides" : true, + "show_inline_toolbar_for_r_code_chunks" : true, + "show_invisibles" : true, + "show_line_numbers" : true, + "show_margin" : true, + "show_memory_usage" : true, + "show_panel_focus_rectangle" : true, + "soft_wrap_r_files" : true, + "source_with_echo" : true, + "spelling_dictionary_language" : "en_US", + "strip_trailing_whitespace" : true, + "style_diagnostics" : true, + "sync_files_pane_working_dir" : true, + "syntax_color_console" : true, + "terminal_close_behavior" : "never", + "use_tinytex" : true, + "vertically_align_arguments_indent" : false, + "view_dir_after_r_cmd_check" : true, + "visual_markdown_code_editor_line_numbers" : true, + "visual_markdown_editing_list_spacing" : "tight", + "visual_markdown_editing_references_location" : "section", + "visual_markdown_editing_show_margin" : true, + "warn_if_no_such_variable_in_scope" : true, + "warn_variable_defined_but_not_used" : true, + "windows_terminal_shell" : "win-git-bash" +} diff --git a/inst/rs-settings/rstudio-prefs--bio-default.json b/inst/rs-settings/rstudio-prefs--bio-default.json index 217d7488..857c5e5e 100644 --- a/inst/rs-settings/rstudio-prefs--bio-default.json +++ b/inst/rs-settings/rstudio-prefs--bio-default.json @@ -56,7 +56,6 @@ "highlight_web_link" : true, "initial_working_directory" : "~/R/darbinis", "insert_matching" : true, - "insert_native_pipe_operator" : false, "insert_native_pipe_operator" : true, "insert_parens_after_function_completion" : true, "insert_spaces_around_equals" : true, diff --git a/inst/rs-settings/rstudio-prefs--rstudio-default-2022.json b/inst/rs-settings/rstudio-prefs--rstudio-default-2022.json new file mode 100644 index 00000000..21a19f6d --- /dev/null +++ b/inst/rs-settings/rstudio-prefs--rstudio-default-2022.json @@ -0,0 +1,208 @@ +{ + "allow_source_columns" : true, + "always_enable_rnw_concordance" : true, + "always_save_history" : true, + "ansi_console_mode" : "on", + "auto_append_newline" : false, + "auto_detect_indentation" : false, + "auto_discover_package_dependencies" : true, + "auto_expand_error_tracebacks" : false, + "auto_run_setup_chunk" : true, + "auto_save_idle_ms" : 1000, + "auto_save_on_blur" : false, + "auto_save_on_idle" : "backup", + "background_diagnostics" : true, + "blinking_cursor" : true, + "busy_detection" : "always", + "check_arguments_to_r_function_calls" : false, + "check_for_updates" : true, + "check_null_external_pointers" : false, + "check_unexpected_assignment_in_function_call" : false, + "clang_verbose" : 0, + "clean_before_install" : true, + "clean_texi2dvi_output" : true, + "cleanup_after_r_cmd_check" : true, + "code_completion" : "always", + "code_completion_characters" : 3, + "code_completion_delay" : 250, + "code_completion_other" : "always", + "command_palette_mru" : true, + "console_code_completion" : true, + "console_double_click_select" : false, + "console_line_length_limit" : 1000, + "console_max_lines" : 1000, + "console_suspend_blocked_notice" : true, + "console_suspend_blocked_notice_delay" : 5, + "continue_comments_on_newline" : false, + "cpp_template" : "Rcpp", + "data_viewer_max_cell_size" : 50, + "data_viewer_max_columns" : 50, + "default_latex_program" : "pdfLaTeX", + "default_sweave_engine" : "Sweave", + "diagnostics_in_r_function_calls" : true, + "diagnostics_on_save" : true, + "disabled_aria_live_announcements" : [], + "doc_outline_show" : "sections_only", + "document_load_lint_delay" : 5000, + "editor_keybindings" : "default", + "editor_theme" : "Textmate (default)", + "emoji_skintone" : "(None)", + "enable_screen_reader" : false, + "enable_snippets" : true, + "enable_text_drag" : true, + "execution_behavior" : "statement", + "file_monitor_ignored_components" : [], + "find_panel_legacy_tab_sequence" : false, + "focus_console_after_exec" : false, + "fold_style" : "begin-and-end", + "font_size_points" : 10.0, + "full_project_path_in_window_title" : false, + "git_diff_ignore_whitespace" : false, + "global_theme" : "default", + "graphics_antialiasing" : "default", + "graphics_backend" : "default", + "handle_errors_in_user_code_only" : true, + "help_font_size_points" : 10.0, + "hide_console_on_chunk_execute" : true, + "hide_object_files" : true, + "highlight_code_chunks" : true, + "highlight_console_errors" : true, + "highlight_r_function_calls" : false, + "highlight_selected_line" : false, + "highlight_selected_word" : true, + "highlight_web_link" : true, + "ignore_uppercase_words" : true, + "ignore_words_with_numbers" : true, + "insert_matching" : true, + "insert_native_pipe_operator" : false, + "insert_numbered_latex_sections" : false, + "insert_parens_after_function_completion" : true, + "insert_spaces_around_equals" : true, + "install_pkg_deps_individually" : true, + "jobs_tab_visibility" : "default", + "knit_working_dir" : "default", + "latex_preview_on_cursor_idle" : "always", + "latex_shell_escape" : false, + "launcher_jobs_sort" : "recorded", + "limit_visible_console" : false, + "line_ending_conversion" : "native", + "load_workspace" : true, + "margin_column" : 80, + "memory_query_interval_seconds" : 10, + "native_file_dialogs" : true, + "navigate_to_build_error" : true, + "new_proj_git_init" : false, + "new_proj_use_renv" : false, + "num_spaces_for_tab" : 2, + "packages_pane_enabled" : true, + "pdf_previewer" : "default", + "plumber_viewer_type" : "window", + "posix_terminal_shell" : "default", + "project_safe_startup_seconds" : 30, + "publish_check_certificates" : true, + "python_project_environment_automatic_activate" : true, + "rainbow_parentheses" : false, + "real_time_spellchecking" : true, + "reduced_motion" : false, + "reindent_on_paste" : true, + "relative_line_numbers" : false, + "remove_history_duplicates" : false, + "restore_last_project" : true, + "restore_project_r_version" : true, + "restore_source_document_cursor_position" : true, + "restore_source_documents" : true, + "reuse_sessions_for_project_links" : false, + "rmd_auto_date" : false, + "rmd_chunk_output_inline" : true, + "rmd_viewer_type" : "window", + "run_rprofile_on_resume" : false, + "save_before_sourcing" : true, + "save_files_before_build" : false, + "save_retry_timeout" : 15, + "save_workspace" : "ask", + "screenreader_console_announce_limit" : 25, + "scroll_past_end_of_document" : false, + "server_editor_font_enabled" : false, + "session_protocol_debug" : false, + "shiny_background_jobs" : false, + "shiny_viewer_type" : "window", + "show_diagnostics_cpp" : true, + "show_diagnostics_other" : false, + "show_diagnostics_r" : true, + "show_diagnostics_yaml" : true, + "show_doc_outline_rmd" : false, + "show_focus_rectangles" : true, + "show_function_signature_tooltips" : true, + "show_help_tooltip_on_idle" : false, + "show_hidden_files" : false, + "show_indent_guides" : false, + "show_inline_toolbar_for_r_code_chunks" : true, + "show_internal_functions" : false, + "show_invisibles" : false, + "show_last_dot_value" : false, + "show_launcher_jobs_tab" : true, + "show_line_numbers" : true, + "show_margin" : true, + "show_memory_usage" : true, + "show_panel_focus_rectangle" : false, + "show_publish_diagnostics" : false, + "show_rmd_render_command" : false, + "show_terminal_tab" : true, + "show_user_home_page" : "sessions", + "soft_wrap_r_files" : false, + "soft_wrap_rmd_files" : true, + "sort_file_names_naturally" : true, + "source_with_echo" : false, + "spelling_custom_dictionaries" : [], + "spelling_dictionary_language" : "en_US", + "ssh_key_type" : "ed25519", + "strip_trailing_whitespace" : false, + "style_diagnostics" : false, + "submit_crash_reports" : true, + "surround_selection" : "quotes_and_brackets", + "sync_files_pane_working_dir" : false, + "syntax_color_console" : false, + "tab_completion" : true, + "tab_key_move_focus" : false, + "tab_multiline_completion" : false, + "terminal_bell_style" : "sound", + "terminal_close_behavior" : "always", + "terminal_initial_directory" : "project", + "terminal_local_echo" : true, + "terminal_python_integration" : true, + "terminal_renderer" : "canvas", + "terminal_track_environment" : true, + "terminal_weblinks" : true, + "terminal_websockets" : true, + "toolbar_visible" : true, + "typing_status_delay_ms" : 2000, + "ui_language" : "en", + "use_dataimport" : true, + "use_devtools" : true, + "use_internet2" : true, + "use_newlines_in_makefiles" : true, + "use_publish_ca_bundle" : false, + "use_roxygen" : false, + "use_secure_download" : true, + "use_spaces_for_tab" : true, + "use_tinytex" : false, + "vcs_autorefresh" : true, + "vcs_enabled" : true, + "vertically_align_arguments_indent" : true, + "view_dir_after_r_cmd_check" : false, + "visual_markdown_code_editor" : "ace", + "visual_markdown_code_editor_line_numbers" : false, + "visual_markdown_editing_canonical" : false, + "visual_markdown_editing_is_default" : false, + "visual_markdown_editing_list_spacing" : "spaced", + "visual_markdown_editing_max_content_width" : 700, + "visual_markdown_editing_references_location" : "block", + "visual_markdown_editing_show_doc_outline" : true, + "visual_markdown_editing_show_margin" : false, + "visual_markdown_editing_wrap" : "none", + "visual_markdown_editing_wrap_at_column" : 72, + "warn_if_no_such_variable_in_scope" : false, + "warn_variable_defined_but_not_used" : false, + "windows_terminal_shell" : "default", + "wrap_tab_navigation" : true +} diff --git a/inst/rs-settings/rstudio-prefs--rstudio-default.json b/inst/rs-settings/rstudio-prefs--rstudio-default.json index 21a19f6d..3116e449 100644 --- a/inst/rs-settings/rstudio-prefs--rstudio-default.json +++ b/inst/rs-settings/rstudio-prefs--rstudio-default.json @@ -1,208 +1,242 @@ { - "allow_source_columns" : true, - "always_enable_rnw_concordance" : true, - "always_save_history" : true, - "ansi_console_mode" : "on", - "auto_append_newline" : false, - "auto_detect_indentation" : false, - "auto_discover_package_dependencies" : true, - "auto_expand_error_tracebacks" : false, - "auto_run_setup_chunk" : true, - "auto_save_idle_ms" : 1000, - "auto_save_on_blur" : false, - "auto_save_on_idle" : "backup", - "background_diagnostics" : true, - "blinking_cursor" : true, - "busy_detection" : "always", - "check_arguments_to_r_function_calls" : false, - "check_for_updates" : true, - "check_null_external_pointers" : false, - "check_unexpected_assignment_in_function_call" : false, - "clang_verbose" : 0, - "clean_before_install" : true, - "clean_texi2dvi_output" : true, - "cleanup_after_r_cmd_check" : true, - "code_completion" : "always", - "code_completion_characters" : 3, - "code_completion_delay" : 250, - "code_completion_other" : "always", - "command_palette_mru" : true, - "console_code_completion" : true, - "console_double_click_select" : false, - "console_line_length_limit" : 1000, - "console_max_lines" : 1000, - "console_suspend_blocked_notice" : true, - "console_suspend_blocked_notice_delay" : 5, - "continue_comments_on_newline" : false, - "cpp_template" : "Rcpp", - "data_viewer_max_cell_size" : 50, - "data_viewer_max_columns" : 50, - "default_latex_program" : "pdfLaTeX", - "default_sweave_engine" : "Sweave", - "diagnostics_in_r_function_calls" : true, - "diagnostics_on_save" : true, - "disabled_aria_live_announcements" : [], - "doc_outline_show" : "sections_only", - "document_load_lint_delay" : 5000, - "editor_keybindings" : "default", - "editor_theme" : "Textmate (default)", - "emoji_skintone" : "(None)", - "enable_screen_reader" : false, - "enable_snippets" : true, - "enable_text_drag" : true, - "execution_behavior" : "statement", - "file_monitor_ignored_components" : [], - "find_panel_legacy_tab_sequence" : false, - "focus_console_after_exec" : false, - "fold_style" : "begin-and-end", - "font_size_points" : 10.0, - "full_project_path_in_window_title" : false, - "git_diff_ignore_whitespace" : false, - "global_theme" : "default", - "graphics_antialiasing" : "default", - "graphics_backend" : "default", - "handle_errors_in_user_code_only" : true, - "help_font_size_points" : 10.0, - "hide_console_on_chunk_execute" : true, - "hide_object_files" : true, - "highlight_code_chunks" : true, - "highlight_console_errors" : true, - "highlight_r_function_calls" : false, - "highlight_selected_line" : false, - "highlight_selected_word" : true, - "highlight_web_link" : true, - "ignore_uppercase_words" : true, - "ignore_words_with_numbers" : true, - "insert_matching" : true, - "insert_native_pipe_operator" : false, - "insert_numbered_latex_sections" : false, - "insert_parens_after_function_completion" : true, - "insert_spaces_around_equals" : true, - "install_pkg_deps_individually" : true, - "jobs_tab_visibility" : "default", - "knit_working_dir" : "default", - "latex_preview_on_cursor_idle" : "always", - "latex_shell_escape" : false, - "launcher_jobs_sort" : "recorded", - "limit_visible_console" : false, - "line_ending_conversion" : "native", - "load_workspace" : true, - "margin_column" : 80, - "memory_query_interval_seconds" : 10, - "native_file_dialogs" : true, - "navigate_to_build_error" : true, - "new_proj_git_init" : false, - "new_proj_use_renv" : false, - "num_spaces_for_tab" : 2, - "packages_pane_enabled" : true, - "pdf_previewer" : "default", - "plumber_viewer_type" : "window", - "posix_terminal_shell" : "default", - "project_safe_startup_seconds" : 30, - "publish_check_certificates" : true, - "python_project_environment_automatic_activate" : true, - "rainbow_parentheses" : false, - "real_time_spellchecking" : true, - "reduced_motion" : false, - "reindent_on_paste" : true, - "relative_line_numbers" : false, - "remove_history_duplicates" : false, - "restore_last_project" : true, - "restore_project_r_version" : true, - "restore_source_document_cursor_position" : true, - "restore_source_documents" : true, - "reuse_sessions_for_project_links" : false, - "rmd_auto_date" : false, - "rmd_chunk_output_inline" : true, - "rmd_viewer_type" : "window", - "run_rprofile_on_resume" : false, - "save_before_sourcing" : true, - "save_files_before_build" : false, - "save_retry_timeout" : 15, - "save_workspace" : "ask", - "screenreader_console_announce_limit" : 25, - "scroll_past_end_of_document" : false, - "server_editor_font_enabled" : false, - "session_protocol_debug" : false, - "shiny_background_jobs" : false, - "shiny_viewer_type" : "window", - "show_diagnostics_cpp" : true, - "show_diagnostics_other" : false, - "show_diagnostics_r" : true, - "show_diagnostics_yaml" : true, - "show_doc_outline_rmd" : false, - "show_focus_rectangles" : true, - "show_function_signature_tooltips" : true, - "show_help_tooltip_on_idle" : false, - "show_hidden_files" : false, - "show_indent_guides" : false, - "show_inline_toolbar_for_r_code_chunks" : true, - "show_internal_functions" : false, - "show_invisibles" : false, - "show_last_dot_value" : false, - "show_launcher_jobs_tab" : true, - "show_line_numbers" : true, - "show_margin" : true, - "show_memory_usage" : true, - "show_panel_focus_rectangle" : false, - "show_publish_diagnostics" : false, - "show_rmd_render_command" : false, - "show_terminal_tab" : true, - "show_user_home_page" : "sessions", - "soft_wrap_r_files" : false, - "soft_wrap_rmd_files" : true, - "sort_file_names_naturally" : true, - "source_with_echo" : false, - "spelling_custom_dictionaries" : [], - "spelling_dictionary_language" : "en_US", - "ssh_key_type" : "ed25519", - "strip_trailing_whitespace" : false, - "style_diagnostics" : false, - "submit_crash_reports" : true, - "surround_selection" : "quotes_and_brackets", - "sync_files_pane_working_dir" : false, - "syntax_color_console" : false, - "tab_completion" : true, - "tab_key_move_focus" : false, - "tab_multiline_completion" : false, - "terminal_bell_style" : "sound", - "terminal_close_behavior" : "always", - "terminal_initial_directory" : "project", - "terminal_local_echo" : true, - "terminal_python_integration" : true, - "terminal_renderer" : "canvas", - "terminal_track_environment" : true, - "terminal_weblinks" : true, - "terminal_websockets" : true, - "toolbar_visible" : true, - "typing_status_delay_ms" : 2000, - "ui_language" : "en", - "use_dataimport" : true, - "use_devtools" : true, - "use_internet2" : true, - "use_newlines_in_makefiles" : true, - "use_publish_ca_bundle" : false, - "use_roxygen" : false, - "use_secure_download" : true, - "use_spaces_for_tab" : true, - "use_tinytex" : false, - "vcs_autorefresh" : true, - "vcs_enabled" : true, - "vertically_align_arguments_indent" : true, - "view_dir_after_r_cmd_check" : false, - "visual_markdown_code_editor" : "ace", - "visual_markdown_code_editor_line_numbers" : false, - "visual_markdown_editing_canonical" : false, - "visual_markdown_editing_is_default" : false, - "visual_markdown_editing_list_spacing" : "spaced", - "visual_markdown_editing_max_content_width" : 700, - "visual_markdown_editing_references_location" : "block", - "visual_markdown_editing_show_doc_outline" : true, - "visual_markdown_editing_show_margin" : false, - "visual_markdown_editing_wrap" : "none", - "visual_markdown_editing_wrap_at_column" : 72, - "warn_if_no_such_variable_in_scope" : false, - "warn_variable_defined_but_not_used" : false, - "windows_terminal_shell" : "default", - "wrap_tab_navigation" : true + "allow_source_columns" : true, + "always_enable_rnw_concordance" : true, + "always_save_history" : true, + "ansi_console_mode" : "on", + "auto_append_newline" : false, + "auto_detect_indentation" : false, + "auto_discover_package_dependencies" : true, + "auto_expand_error_tracebacks" : false, + "auto_run_setup_chunk" : true, + "auto_save_idle_ms" : 1000, + "auto_save_on_blur" : false, + "auto_save_on_idle" : "backup", + "background_diagnostics" : true, + "background_diagnostics_delay_ms" : 2000, + "bioconductor_mirror_name" : "Seattle (USA)", + "bioconductor_mirror_url" : "http://www.bioconductor.org", + "blinking_cursor" : true, + "busy_detection" : "always", + "busy_exclusion_list" : ["tmux", "screen"], + "check_arguments_to_r_function_calls" : false, + "check_for_updates" : true, + "check_null_external_pointers" : false, + "check_unexpected_assignment_in_function_call" : false, + "clang_verbose" : 0, + "clean_before_install" : true, + "clean_texi2dvi_output" : true, + "cleanup_after_r_cmd_check" : true, + "code_completion" : "always", + "code_completion_characters" : 3, + "code_completion_delay" : 250, + "code_completion_other" : "always", + "color_preview" : true, + "command_palette_mru" : true, + "console_code_completion" : true, + "console_double_click_select" : false, + "console_line_length_limit" : 1000, + "console_max_lines" : 1000, + "console_suspend_blocked_notice" : true, + "console_suspend_blocked_notice_delay" : 5, + "continue_comments_on_newline" : false, + "cpp_template" : "Rcpp", + "cran_mirror" : {}, + "custom_shell_command" : "", + "custom_shell_options" : "", + "data_viewer_max_cell_size" : 50, + "data_viewer_max_columns" : 50, + "default_encoding" : "", + "default_latex_program" : "pdfLaTeX", + "default_project_location" : "", + "default_r_version" : {}, + "default_sweave_engine" : "Sweave", + "diagnostics_in_r_function_calls" : true, + "diagnostics_on_save" : true, + "disable_renderer_accessibility" : false, + "disabled_aria_live_announcements" : [], + "discard_pending_console_input_on_error" : true, + "doc_outline_show" : "sections_only", + "document_author" : "", + "document_load_lint_delay" : 5000, + "editor_keybindings" : "default", + "editor_scroll_multiplier" : 100, + "editor_theme" : "Textmate (default)", + "emoji_skintone" : "(None)", + "enable_cloud_publish_ui" : true, + "enable_screen_reader" : false, + "enable_snippets" : true, + "enable_text_drag" : true, + "execution_behavior" : "statement", + "file_monitor_ignored_components" : [], + "find_panel_legacy_tab_sequence" : false, + "focus_console_after_exec" : false, + "fold_style" : "begin-and-end", + "font_size_points" : 10, + "full_project_path_in_window_title" : false, + "git_diff_ignore_whitespace" : false, + "git_exe_path" : "", + "global_theme" : "default", + "graphics_antialiasing" : "default", + "graphics_backend" : "default", + "handle_errors_in_user_code_only" : true, + "help_font_size_points" : 10, + "hide_console_on_chunk_execute" : true, + "hide_object_files" : true, + "highlight_code_chunks" : true, + "highlight_console_errors" : true, + "highlight_r_function_calls" : false, + "highlight_selected_line" : false, + "highlight_selected_word" : true, + "highlight_web_link" : true, + "ignore_uppercase_words" : true, + "ignore_words_with_numbers" : true, + "indent_guides" : "none", + "initial_working_directory" : "", + "insert_matching" : true, + "insert_native_pipe_operator" : false, + "insert_numbered_latex_sections" : false, + "insert_parens_after_function_completion" : true, + "insert_spaces_around_equals" : true, + "install_pkg_deps_individually" : true, + "jobs_tab_visibility" : "default", + "knit_working_dir" : "default", + "latex_preview_on_cursor_idle" : "always", + "latex_shell_escape" : false, + "launcher_jobs_sort" : "recorded", + "limit_visible_console" : false, + "line_ending_conversion" : "native", + "load_workspace" : true, + "margin_column" : 80, + "memory_query_interval_seconds" : 10, + "native_file_dialogs" : true, + "navigate_to_build_error" : true, + "new_proj_git_init" : false, + "new_proj_use_renv" : false, + "num_spaces_for_tab" : 2, + "packages_pane_enabled" : true, + "panes" : {}, + "pdf_previewer" : "default", + "plumber_viewer_type" : "window", + "posix_terminal_shell" : "default", + "project_safe_startup_seconds" : 30, + "publish_ca_bundle" : "", + "publish_check_certificates" : true, + "python_path" : "", + "python_project_environment_automatic_activate": true, + "python_type" : "", + "python_version" : "", + "rainbow_fenced_divs" : true, + "rainbow_parentheses" : false, + "real_time_spellchecking" : true, + "reduced_motion" : false, + "reindent_on_paste" : true, + "relative_line_numbers" : false, + "remove_history_duplicates" : false, + "restore_last_project" : true, + "restore_project_r_version" : true, + "restore_source_document_cursor_position" : true, + "restore_source_documents" : true, + "reuse_sessions_for_project_links" : false, + "rmd_auto_date" : false, + "rmd_chunk_output_inline" : true, + "rmd_preferred_template_path" : "", + "rmd_viewer_type" : "window", + "root_document" : "", + "rsa_key_path" : "", + "run_rprofile_on_resume" : false, + "save_before_sourcing" : true, + "save_files_before_build" : false, + "save_retry_timeout" : 15, + "save_workspace" : "ask", + "screenreader_console_announce_limit" : 25, + "scroll_past_end_of_document" : false, + "server_editor_font" : "", + "server_editor_font_enabled" : false, + "session_protocol_debug" : false, + "shiny_background_jobs" : false, + "shiny_viewer_type" : "window", + "show_diagnostics_cpp" : true, + "show_diagnostics_other" : false, + "show_diagnostics_r" : true, + "show_diagnostics_yaml" : true, + "show_doc_outline_rmd" : false, + "show_focus_rectangles" : true, + "show_function_signature_tooltips" : true, + "show_help_tooltip_on_idle" : false, + "show_hidden_files" : false, + "show_inline_toolbar_for_r_code_chunks" : true, + "show_internal_functions" : false, + "show_invisibles" : false, + "show_last_dot_value" : false, + "show_launcher_jobs_tab" : true, + "show_line_numbers" : true, + "show_margin" : true, + "show_memory_usage" : true, + "show_panel_focus_rectangle" : false, + "show_publish_diagnostics" : false, + "show_rmd_render_command" : false, + "show_terminal_tab" : true, + "show_user_home_page" : "sessions", + "soft_wrap_r_files" : false, + "soft_wrap_rmd_files" : true, + "sort_file_names_naturally" : true, + "source_with_echo" : false, + "spelling_custom_dictionaries" : [], + "spelling_dictionary_language" : "en_US", + "ssh_key_type" : "ed25519", + "strip_trailing_whitespace" : false, + "style_diagnostics" : false, + "submit_crash_reports" : true, + "surround_selection" : "quotes_and_brackets", + "svn_exe_path" : "", + "sync_files_pane_working_dir" : false, + "syntax_color_console" : false, + "tab_completion" : true, + "tab_key_move_focus" : false, + "tab_multiline_completion" : false, + "terminal_bell_style" : "sound", + "terminal_close_behavior" : "always", + "terminal_initial_directory" : "project", + "terminal_local_echo" : true, + "terminal_path" : "", + "terminal_python_integration" : true, + "terminal_renderer" : "canvas", + "terminal_track_environment" : true, + "terminal_weblinks" : true, + "terminal_websockets" : true, + "text_rendering" : "auto", + "toolbar_visible" : true, + "typing_status_delay_ms" : 2000, + "ui_language" : "en", + "use_dataimport" : true, + "use_devtools" : true, + "use_internet2" : true, + "use_newlines_in_makefiles" : true, + "use_publish_ca_bundle" : false, + "use_roxygen" : false, + "use_secure_download" : true, + "use_spaces_for_tab" : true, + "use_tinytex" : false, + "vcs_autorefresh" : true, + "vcs_enabled" : true, + "vertically_align_arguments_indent" : true, + "view_dir_after_r_cmd_check" : false, + "visual_markdown_code_editor" : "ace", + "visual_markdown_code_editor_line_numbers" : false, + "visual_markdown_editing_canonical" : false, + "visual_markdown_editing_font_size_points" : 0, + "visual_markdown_editing_is_default" : false, + "visual_markdown_editing_list_spacing" : "spaced", + "visual_markdown_editing_max_content_width" : 700, + "visual_markdown_editing_references_location" : "block", + "visual_markdown_editing_show_doc_outline" : true, + "visual_markdown_editing_show_margin" : false, + "visual_markdown_editing_wrap" : "none", + "visual_markdown_editing_wrap_at_column" : 72, + "warn_if_no_such_variable_in_scope" : false, + "warn_variable_defined_but_not_used" : false, + "windows_terminal_shell" : "default", + "wrap_tab_navigation" : true, + "zotero_libraries" : ["My Library"] } + diff --git a/man/emokymai.Rd b/man/emokymai.Rd deleted file mode 100644 index f4caf137..00000000 --- a/man/emokymai.Rd +++ /dev/null @@ -1,18 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/u_task_names.R -\name{emokymai} -\alias{emokymai} -\alias{emokymai_browse_assingment} -\alias{emokymai_submit_assingment} -\title{Open Resource on Emokymai} -\usage{ -emokymai_browse_assingment(id) - -emokymai_submit_assingment(id) -} -\arguments{ -\item{id}{Resource ID.} -} -\description{ -Open Resource on Emokymai -} diff --git a/man/pkg_list_archived_versions.Rd b/man/pkg_list_archived_versions.Rd new file mode 100644 index 00000000..59411dfe --- /dev/null +++ b/man/pkg_list_archived_versions.Rd @@ -0,0 +1,23 @@ +% Generated by roxygen2: do not edit by hand +% Please edit documentation in R/packages--check.R +\name{pkg_list_archived_versions} +\alias{pkg_list_archived_versions} +\title{Get previous package versions available on CRAN} +\usage{ +pkg_list_archived_versions(package) +} +\arguments{ +\item{package}{(character) +Package name.} +} +\value{ +Vector with version numbers (the current version is not present). +} +\description{ +Function to scrape the CRAN website and retrieve archived (old) package versions +} +\examples{ +pkg_list_archived_versions("ggplot2") + +pkg_list_archived_versions("none") +} diff --git a/man/spelling.Rd b/man/spelling.Rd index 1ccefd3a..a06bbb4a 100644 --- a/man/spelling.Rd +++ b/man/spelling.Rd @@ -4,7 +4,6 @@ \alias{spelling} \alias{rstudio_install_spellcheck_dictionaries} \alias{rstudio_download_spellcheck_dictionaries} -\alias{rstudio_install_spellcheck_dictionary_lt} \alias{rstudio_delete_spellcheck_dictionaries} \title{Dictionaries to check spelling} \usage{ @@ -12,8 +11,6 @@ rstudio_install_spellcheck_dictionaries(secure = TRUE) rstudio_download_spellcheck_dictionaries(secure = TRUE) -rstudio_install_spellcheck_dictionary_lt() - rstudio_delete_spellcheck_dictionaries(ask = TRUE) } \arguments{ @@ -26,8 +23,6 @@ interactively.} \itemize{ \item \code{rstudio_download_spellcheck_dictionaries()} downloads and updates RStudio (system) spellchecking dictionaries. -\item \code{rstudio_download_spellcheck_dictionaries_lt()} -installs improved Lithuanian spellchecking dictionary. \item \code{rstudio_delete_spellcheck_dictionaries()} deletes RStudio (system) spellchecking dictionaries. } @@ -36,7 +31,6 @@ deletes RStudio (system) spellchecking dictionaries. \dontrun{\donttest{ rstudio_delete_spellcheck_dictionaries() rstudio_download_spellcheck_dictionaries() -rstudio_install_spellcheck_dictionary_lt() }} } \concept{dictionaries} diff --git a/man/to_ascii_lower.Rd b/man/to_ascii_lower.Rd deleted file mode 100644 index a471388f..00000000 --- a/man/to_ascii_lower.Rd +++ /dev/null @@ -1,22 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/u_task_names.R -\name{to_ascii_lower} -\alias{to_ascii_lower} -\title{Transliterate to ASCII Lower-Case Symbol} -\usage{ -to_ascii_lower(x) -} -\arguments{ -\item{x}{A string or a character vector.} -} -\value{ -A modified string or character vector. -} -\description{ -Transliterate all symbols in a string into lower-case ASCII symbols. -} -\examples{ -to_ascii_lower("AbD") -to_ascii_lower(c("AAA", "BbB")) - -} diff --git a/man/u_prepare_assignment_dc.Rd b/man/u_prepare_assignment_dc.Rd deleted file mode 100644 index 35d7556b..00000000 --- a/man/u_prepare_assignment_dc.Rd +++ /dev/null @@ -1,57 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/u_task_names.R -\name{u_prepare_assignment_dc} -\alias{u_prepare_assignment_dc} -\title{Prepare Files For Submission (DataCamp Task)} -\usage{ -u_prepare_assignment_dc( - uzduoties_nr, - varianto_nr, - specialybe, - pavarde, - vardas, - sertifikatas, - konspektas, - open_dir = FALSE, - emokymai_id = NULL -) -} -\arguments{ -\item{uzduoties_nr}{(integer)} - -\item{varianto_nr}{(integer)} - -\item{specialybe}{(string)} - -\item{pavarde}{(string)} - -\item{vardas}{(string)} - -\item{sertifikatas}{(string) Path to PDF file -(certificate issued by DataCamp).} - -\item{konspektas}{(string) Path to PDF file.} - -\item{open_dir}{(\code{TRUE}|\code{FALSE}) Open the directory with submission files.} - -\item{emokymai_id}{(integer) Open the directory with submission files.} -} -\description{ -The function creates a folder (e.g.,\code{U00-atsakymai-ikelimui}) and copies files -indicated in \code{sertifikatas} and \code{konspektas} to that folder. -The copied files are properly renamed. -If needed, the function opens the folder and assignment submission webpage. -} -\examples{ -if (FALSE) { - u_prepare_assignment_dc( - uzduoties_nr = 1, - varianto_nr = 000, - specialybe = "molekuline biologija", - pavarde = "Pavarde", - vardas = "Vardas Antras", - sertifikatas = "pratybos/certificate.pdf", - konspektas = "pratybos/konspektas.pdf" - ) -} -} diff --git a/man/u_task.Rd b/man/u_task.Rd deleted file mode 100644 index acc01c5c..00000000 --- a/man/u_task.Rd +++ /dev/null @@ -1,87 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/u_task_names.R -\name{u_task} -\alias{u_task} -\alias{u_create_filename} -\alias{u_parse_filename} -\alias{u_check_filename} -\title{Create Filename for Type U Task} -\usage{ -u_create_filename( - uzduoties_nr, - varianto_nr, - specialybe, - pavarde, - vardas, - patikslinimas = "", - dokumento_formatas = NULL -) - -u_parse_filename(x) - -u_check_filename(x) -} -\arguments{ -\item{uzduoties_nr}{(integer) The number of U task.} - -\item{varianto_nr}{(integer) The variant of the task. -Each student has a unique personal variant number.} - -\item{specialybe}{(character) Name of study program.} - -\item{pavarde}{(character) Family name (names).} - -\item{vardas}{(character) Sure name (names).} - -\item{patikslinimas}{(character) Additional information.} - -\item{dokumento_formatas}{(character) File name extension.} - -\item{x}{(character) A file name to parse or to check if it's structure -is correct.} -} -\value{ -\itemize{ -\item \code{u_create_filename()} returns sting with formatted file name. -\item \code{u_parse_filename()} returns data frame with details extracted from -the filename. -\item \code{u_check_filename()} returns \code{TRUE} if the structure of file name is -correct and \code{FALSE} otherwise. -} -} -\description{ -Create a name for a file or folder which should be submitted as a "U" task. -} -\examples{ -u_create_filename( - uzduoties_nr = 1, - varianto_nr = 000, - specialybe = "molekuline biologija", - pavarde = "Pavarde", - vardas = "Vardas Antras", - patikslinimas = "sertifikatas", - dokumento_formatas = "pdf" -) - -u_create_filename( - uzduoties_nr = 10, - varianto_nr = 000, - specialybe = "molekuline biologija", - pavarde = "Pavarde", - vardas = "Vardas Antras" -) - -x <- "U01-v000-[molbio]-[Pavarde]-[Vardas-Antras]-sertifikatas.pdf" - -u_check_filename("U01-v000-[molbio]-[Pavarde]-[Vardas-Antras]-sertifikatas.pdf") -u_parse_filename("U01-v000-[molbio]-[Pavarde]-[Vardas-Antras]-sertifikatas.pdf") - -u_check_filename("U03-v000-[molekuline]-[Pavarde]-[Vardas].zip") -u_parse_filename("U03-v000-[molekuline]-[Pavarde]-[Vardas].zip") - -u_check_filename("U03-v000-[biofiz]-[Pavarde]-[Vardas]") -u_parse_filename("U03-v000-[biofiz]-[Pavarde]-[Vardas]") - -# Incorrect family name: -u_parse_filename("U03-v000-[molekuline]-[Pavarde3]-[Vardas].zip") -}