Description Usage Arguments Details Value Author(s) See Also Examples
Creates a dummy string of text, saves a text file in base::tempdir.
| 1 2 3 4 5 6 7 | fakeTextFile(
  file_extension = ".R",
  dir_path = NULL,
  file_path = NULL,
  txt = NULL,
  n_lines = 1
)
 | 
| file_extension | Character value. File extension, default value is '.R' | 
| dir_path | A character vector with the path to the folder where to save the text file.
Default value is NULL and uses  | 
| file_path | A character vector with the path, file name and extension of the created random file. | 
| txt | An optional string (one line) or list of strings (multiple lines) to save in the text file. Randomly generated by default | 
| n_lines | Positive none zero integer value. If 'txt' is not provided, 'n_lines' is the number of lines of text in the file. | 
If not working inside an R project, dir_path has to be complete from root. To create an empty file, use 'txt = ""'.
A list with two elements: - tmp_path: the path to the fake text file - txt: the dummy text string or list of strings
Alban Sagouis
For more flexibility in random string generation, see NCmisc::fakeLines.
For more automated paragraph generation, see stringi::stri_rand_lipsum.
| 1 | ## Not run: fakeTextFile()
 | 
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.