xfun (version 0.12)

file_string: Read a text file and concatenate the lines by '\n'

Description

The source code of this function should be self-explanatory.

Usage

file_string(file)

Arguments

file

Path to a text file (should be encoded in UTF-8).

Value

A character string of text lines concatenated by '\n'.

Examples

Run this code
# NOT RUN {
xfun::file_string(system.file("DESCRIPTION", package = "xfun"))
# }

Run the code above in your browser using DataCamp Workspace