rename_script_numbers: Iteratively renames files in a directory using the...

Description Usage Arguments Examples

Description

Iteratively renames files in a directory using the 'renumber_file' function

Usage

1
2
rename_script_numbers(path, number_match_pattern, pad_width,
  rfile_pattern = "*.[rR]$", dry_run = TRUE, verbose = TRUE)

Arguments

path:

directory of files

number_match_pattern:

pattern passed into 'renumber_file'

pad_width:

left pad width passed into 'renumber_file'

rfile_pattern:

regular expression that looks for files to rename, defaults to looking for r script files

dry_run:

whether or not to actually do the rename or not. defaults to TRUE, which does not rename files, only prints out pre and post file names

verbose:

whether or not to show print statments

Examples

1
2
3
4
rename_script_numbers(path = '~/git/lab/dspg_17/oss/data/oss/original/openhub/users/user_tables/',
                      number_match_pattern = '\\d*\\.RData$',
                      pad_width = 3,
                      rfile_pattern = '*.[rRdD]ata')

bi-sdal/sdalr documentation built on May 12, 2019, 8:29 p.m.