Scheduled service maintenance on November 22


On Friday, November 22, 2024, between 06:00 CET and 18:00 CET, GIN services will undergo planned maintenance. Extended service interruptions should be expected. We will try to keep downtimes to a minimum, but recommend that users avoid critical tasks, large data uploads, or DOI requests during this time.

We apologize for any inconvenience.

createfolderfromGooglesheet.r 1.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. library (googlesheets4)
  2. gs_auth()
  3. #
  4. template_f = gs_url ("https://docs.google.com/spreadsheets/d/1rrl2QcBIQNIQ-D5ugH7FuaiVckItAQxRVlW-Jgb9sdo/edit?ts=5ee10875#gid=1035048464")
  5. #
  6. # data= googlesheets::gs_read_csv(PIlist, skip =2)
  7. template_data <- read_sheet("https://docs.google.com/spreadsheets/d/1rrl2QcBIQNIQ-D5ugH7FuaiVckItAQxRVlW-Jgb9sdo/edit?ts=5ee10875#gid=1035048464")
  8. createtemplate <- function(dirname ="template1", template_data) {
  9. dir.create(dirname)
  10. setwd(dirname)
  11. template_dataf = template_data [(template_data$create != "NULL"),]
  12. for (i in c(nrow(template_dataf):1)){
  13. if (nchar(template_dataf$create[i])<2) {
  14. dir.create(template_dataf$alternative_name[i])
  15. file.create(paste0(template_dataf$alternative_name[i], "/gitdir"))
  16. file.rename(template_dataf$alternative_name[i], paste0 ("0",template_dataf$create[i],"_",template_dataf$alternative_name[i]))
  17. } else {
  18. dir.create(paste0(template_dataf$create[i], "/",template_dataf$alternative_name[i]), recursive = TRUE)
  19. file.create(paste0(template_dataf$create[i], "/",template_dataf$alternative_name[i], "/gitdir"))
  20. }
  21. }
  22. setwd("../")
  23. }
  24. #setwd("20_deriveddata")
  25. template_data$create = as.character(template_data$upfolder_2)
  26. createtemplate(dirname ="template1",template_data)
  27. template_data$create = as.character(template_data$unitial_upfolder)
  28. createtemplate(dirname ="template_ori",template_data)
  29. template_data$create = as.character(template_data$upfolder_3)
  30. createtemplate(dirname ="template_3",template_data)