Skip to content

Commit

Permalink
Merge pull request #22 from A2-ai/cleanup
Browse files Browse the repository at this point in the history
Cleanup
  • Loading branch information
mduncans authored Nov 8, 2024
2 parents 38e1ff4 + 6380e8d commit c2a121b
Show file tree
Hide file tree
Showing 11 changed files with 15 additions and 15 deletions.
2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Package: slurmtools
Title: slurm tooling
Version: 0.0.0.9002
Version: 0.0.0.9003
Authors@R: c(person("Devin", "Pastoor", , "[email protected]", role = c("aut", "cre")),
person("Jenna", "Elwing", email = "[email protected]", role = "aut"),
person("Matthew", "Smith", email = "[email protected]", role = "aut"))
Expand Down
2 changes: 1 addition & 1 deletion NAMESPACE
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ S3method(format_toml,integer)
S3method(format_toml,list)
S3method(format_toml,logical)
S3method(format_toml,name)
export(cancel_job)
export(cancel_slurm_job)
export(generate_nmm_config)
export(get_slurm_jobs)
export(get_slurm_partitions)
Expand Down
6 changes: 3 additions & 3 deletions R/attach.R
Original file line number Diff line number Diff line change
Expand Up @@ -14,21 +14,21 @@ slurmtools_options_message <- function() {
# Check for each used options
tmpl_path <- getOption('slurmtools.slurm_job_template_path')
if (is.null(tmpl_path)) {
unset_options <- c(unset_options, "option('slurmtools.slurm_job_template_path') is not set.")
unset_options <- c(unset_options, "options('slurmtools.slurm_job_template_path') is not set.")
} else {
set_options <- c(set_options, paste("slurmtools.slurm_jon_template_path:", tmpl_path))
}

root <- getOption('slurmtools.submission_root')
if (is.null(root)) {
unset_options <- c(unset_options, "option('slurmtools.submission_root') is not set.")
unset_options <- c(unset_options, "options('slurmtools.submission_root') is not set.")
} else {
set_options <- c(set_options, paste("slurmtools.submission_root:", root))
}

bbi_config <- getOption("slurmtools.bbi_config_path")
if (is.null(bbi_config)) {
unset_options <- c(unset_options, "option('slurmtools.bbi_config_path') is not set.")
unset_options <- c(unset_options, "options('slurmtools.bbi_config_path') is not set.")
} else {
set_options <- c(set_options, paste("slurmtools.bbi_config_path:", bbi_config))
}
Expand Down
2 changes: 1 addition & 1 deletion R/cancel-job.R
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
#' @examples \dontrun{
#' cancel_job(243)
#' }
cancel_job <- function(job_id, user = NULL) {
cancel_slurm_job <- function(job_id, user = NULL) {

current_user = if (is.null(Sys.getenv("USER"))) Sys.info()['user'] else Sys.getenv("USER")

Expand Down
2 changes: 1 addition & 1 deletion R/slurmtools.R
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
#'
#' @section cancelling jobs:
#' \itemize{
#' \item \code{\link{cancel_job}}: Cancels the specified job
#' \item \code{\link{cancel_slurm_job}}: Cancels the specified job
#' }
#'
#' @section slurm partitions:
Expand Down
2 changes: 1 addition & 1 deletion _pkgdown.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ reference:
- submit_nonmem_model
- generate_nmm_config
- get_slurm_jobs
- cancel_job
- cancel_slurm_job
- get_slurm_partitions
- slurmtools

Expand Down
6 changes: 3 additions & 3 deletions man/cancel_job.Rd → man/cancel_slurm_job.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion man/slurmtools.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion vignettes/Running-nonmem.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -254,7 +254,7 @@ jobs <- get_slurm_jobs(user = "matthews") %>%
dplyr::pull(job_id)
for (job in jobs) {
cancel_job(job)
cancel_slurm_job(job)
}
unlink(file.path(nonmem, "1001"), recursive = TRUE)
Expand Down
2 changes: 1 addition & 1 deletion vignettes/custom-alerts.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -237,7 +237,7 @@ jobs <- get_slurm_jobs(user = "matthews") %>%
dplyr::pull(job_id)
for (job in jobs) {
cancel_job(job)
cancel_slurm_job(job)
}
unlink(file.path(nonmem, "1001"), recursive = TRUE)
Expand Down
2 changes: 1 addition & 1 deletion vignettes/slack-alerts.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ jobs <- get_slurm_jobs(user = "matthews") %>%
dplyr::pull(job_id)
for (job in jobs) {
cancel_job(job)
cancel_slurm_job(job)
}
unlink(file.path(nonmem, "1001"), recursive = TRUE)
Expand Down

0 comments on commit c2a121b

Please sign in to comment.