Skip to contents

Create a Pre-defined Directory Hierarchy on Disk

Usage

create_directory_structure(
  path,
  structure_path = system.file("templates", "_project_structure_en.yaml", package =
    "saros.base"),
  numbering_prefix = c("none", "max_local", "max_global"),
  numbering_inheritance = TRUE,
  word_separator = NULL,
  numbering_parent_child_separator = word_separator,
  numbering_name_separator = " ",
  case = c("asis", "sentence", "title", "lower", "upper", "snake"),
  replacement_list = c(project_initials = "SSN"),
  create = FALSE,
  count_existing_folders = FALSE
)

Arguments

path

String, path to where to create the project files

structure_path

String. Path to the YAML file that defines the folder structure. Defaults to system.file("templates", "_project_structure_en.yaml").

numbering_prefix

String. One of c("none", "max_local", "max_global").

numbering_inheritance

Flag. Whether to inherit numbering from parent folder.

word_separator

String. Replace separators between words in folder names. Defaults to NULL.

numbering_parent_child_separator

String. Defaults to word_separator.

numbering_name_separator

String. Separator between numbering part and name.

case

String. One of c("asis", "sentence", "lower", "upper", "title", "snake").

replacement_list

named character vector. Each name in this vector will be replaced with its "{{value}}" in the structure_path file

create

Boolean. Defaults to TRUE in initialize_saros_project(), FALSE in create_directory_structure().

count_existing_folders

Boolean. Defaults to FALSE.

Value

No return value, called for side effects

Examples

create_directory_structure(path = tempdir())
#> /tmp/Rtmpaw0V2x/Administration
#> /tmp/Rtmpaw0V2x/Administration/Application
#> /tmp/Rtmpaw0V2x/Administration/Application/Call
#> /tmp/Rtmpaw0V2x/Administration/Application/Formalities
#> /tmp/Rtmpaw0V2x/Administration/Application/CVs
#> /tmp/Rtmpaw0V2x/Administration/Application/Collaboration and cooperation
#> agreements
#> /tmp/Rtmpaw0V2x/Administration/Application/Application
#> /tmp/Rtmpaw0V2x/Administration/Application/Pre-analysis
#> /tmp/Rtmpaw0V2x/Administration/Application/For submission
#> /tmp/Rtmpaw0V2x/Administration/Budget
#> /tmp/Rtmpaw0V2x/Administration/Contracts and agreements
#> /tmp/Rtmpaw0V2x/Administration/Invoices, accounting and receipts
#> /tmp/Rtmpaw0V2x/Administration/Status reports
#> /tmp/Rtmpaw0V2x/Administration/Logo and graphical materials
#> /tmp/Rtmpaw0V2x/Administration/Internal meetings
#> /tmp/Rtmpaw0V2x/Administration/Internal meetings/Meeting agendas and
#> invitations
#> /tmp/Rtmpaw0V2x/Administration/Internal meetings/Internal presentations
#> /tmp/Rtmpaw0V2x/Administration/Internal meetings/Minutes
#> /tmp/Rtmpaw0V2x/Materials
#> /tmp/Rtmpaw0V2x/Materials/Overall planning
#> /tmp/Rtmpaw0V2x/Materials/Consent form
#> /tmp/Rtmpaw0V2x/Materials/Ethical-GDPR approval
#> /tmp/Rtmpaw0V2x/Materials/Survey questionnaires
#> /tmp/Rtmpaw0V2x/Materials/Interview guides
#> /tmp/Rtmpaw0V2x/Materials/Interview guides/Staff
#> /tmp/Rtmpaw0V2x/Materials/Interview guides/Pupils
#> /tmp/Rtmpaw0V2x/Materials/Interview guides/Parents
#> /tmp/Rtmpaw0V2x/Materials/Interview guides/Researchers
#> /tmp/Rtmpaw0V2x/Materials/Interview guides/Leaders
#> /tmp/Rtmpaw0V2x/Materials/Interview guides/Teachers
#> /tmp/Rtmpaw0V2x/Materials/Interview guides/Principals
#> /tmp/Rtmpaw0V2x/Materials/Interview guides/Students
#> /tmp/Rtmpaw0V2x/Materials/Interview guides/Population
#> /tmp/Rtmpaw0V2x/Materials/Request of data from
#> /tmp/Rtmpaw0V2x/Materials/Literature review-design
#> /tmp/Rtmpaw0V2x/Materials/Intervention materials
#> /tmp/Rtmpaw0V2x/Materials/Randomizing participants
#> /tmp/Rtmpaw0V2x/Materials/Chapter overviews
#> /tmp/Rtmpaw0V2x/Literature
#> /tmp/Rtmpaw0V2x/Literature/Topic has policy relevance
#> /tmp/Rtmpaw0V2x/Literature/Pure theory and framework
#> /tmp/Rtmpaw0V2x/Literature/Similar empirical studies
#> /tmp/Rtmpaw0V2x/Literature/Similar instruments and guides for data collection
#> /tmp/Rtmpaw0V2x/Literature/Relevant analytic methodology
#> /tmp/Rtmpaw0V2x/Literature/Unprocessed (remove from here)
#> /tmp/Rtmpaw0V2x/Data
#> /tmp/Rtmpaw0V2x/Data/Population data
#> /tmp/Rtmpaw0V2x/Data/Population data/Codebook
#> /tmp/Rtmpaw0V2x/Data/Sampling frame
#> /tmp/Rtmpaw0V2x/Data/Registry data
#> /tmp/Rtmpaw0V2x/Data/Collected respondent lists
#> /tmp/Rtmpaw0V2x/Data/Respondent list for survey system
#> /tmp/Rtmpaw0V2x/Data/Downloaded response data
#> /tmp/Rtmpaw0V2x/Data/Downloaded response data/Codebook
#> /tmp/Rtmpaw0V2x/Data/Qualitative data
#> /tmp/Rtmpaw0V2x/Data/Qualitative data/Interview recordings
#> /tmp/Rtmpaw0V2x/Data/Qualitative data/Observational notes
#> /tmp/Rtmpaw0V2x/Data/Text corpus
#> /tmp/Rtmpaw0V2x/Data/PDF-reports
#> /tmp/Rtmpaw0V2x/Data/Prepared data
#> /tmp/Rtmpaw0V2x/Data/Prepared data/Codebooks
#> /tmp/Rtmpaw0V2x/Saros_SSN
#> /tmp/Rtmpaw0V2x/Saros_SSN/Scripts
#> /tmp/Rtmpaw0V2x/Saros_SSN/Resources
#> /tmp/Rtmpaw0V2x/Saros_SSN/Draft generations
#> /tmp/Rtmpaw0V2x/Saros_SSN/Draft generations/main
#> /tmp/Rtmpaw0V2x/Saros_SSN/Draft generations/Reports
#> /tmp/Rtmpaw0V2x/Saros_SSN/Drafts in editing
#> /tmp/Rtmpaw0V2x/Saros_SSN/Drafts in editing/main
#> /tmp/Rtmpaw0V2x/Saros_SSN/Drafts in editing/Reports
#> /tmp/Rtmpaw0V2x/Saros_SSN/Completed drafts
#> /tmp/Rtmpaw0V2x/Saros_SSN/Completed drafts/main
#> /tmp/Rtmpaw0V2x/Saros_SSN/Completed drafts/Reports
#> /tmp/Rtmpaw0V2x/Publications
#> /tmp/Rtmpaw0V2x/Publications/Paper1-Short title (author initials)
#> /tmp/Rtmpaw0V2x/Publications/Paper1-Short title (author initials)/Cover letter
#> & response to reviewers
#> /tmp/Rtmpaw0V2x/Publications/Paper1-Short title (author initials)/Manuscript
#> /tmp/Rtmpaw0V2x/Publications/Paper1-Short title (author initials)/Analysis
#> /tmp/Rtmpaw0V2x/Publications/Paper1-Short title (author initials)/Figures for
#> submission
#> /tmp/Rtmpaw0V2x/Publications/Paper1-Short title (author initials)/Tables for
#> submission
#> /tmp/Rtmpaw0V2x/Publications/Paper1-Short title (author initials)/Appendix
#> /tmp/Rtmpaw0V2x/Publications/Paper1-Short title (author initials)/Online
#> supplementary materials
#> /tmp/Rtmpaw0V2x/Outreach
#> /tmp/Rtmpaw0V2x/Outreach/Research conference presentation
#> /tmp/Rtmpaw0V2x/Outreach/Research conference poster
#> /tmp/Rtmpaw0V2x/Outreach/Stakeholders and reference group
#> /tmp/Rtmpaw0V2x/Outreach/Stakeholders' communication channels
#> /tmp/Rtmpaw0V2x/Outreach/Practitioners and special interest channels
#> /tmp/Rtmpaw0V2x/Outreach/Public through mass media channels
#> /tmp/Rtmpaw0V2x/Other