Skip to content

Commit

Permalink
add simple browser function to download toolbox
Browse files Browse the repository at this point in the history
  • Loading branch information
salvafern committed Apr 12, 2022
1 parent 6188056 commit ae2a8ca
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions R/helper.R
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
#' Browse the LifeWatch/EMODnet-Biology Download Toolbox on your browser
#'
#' @return NULL, only opens the Download Toolbox in your browser.
#' @export
#'
#' @examples eurobis_download_toolbox()
eurobis_download_toolbox <- function(){
url <- eurobis_url$info$toolbox
req <- httr::HEAD(url)
httr::stop_for_status(req)

if(interactive()){
message("The LifeWatch/EMODnet-Biology Download Toolbox provides a web interface to fine tune the selection of data from EurOBIS. At the end of the selection there is a button named \"Get webservice url\". Copy&Paste this URL into eurobis_occurrences(url = \"<URL>\"). Press ENTER to continue:" )
readline("")
browseURL(url)
}

NULL
}

0 comments on commit ae2a8ca

Please sign in to comment.