getfd {toscutil}R Documentation

Get File Directory

Description

Return full path to current file directory

Usage

getfd(
  on.error = stop("No file sourced. Maybe you're in an interactive shell?", call. =
    FALSE),
  winslash = "/"
)

Arguments

on.error

Expression to use if the current file directory cannot be determined. In that case, normalizePath(on.error, winslash) is returned. Can also be an expression like stop("message") to stop execution (default).

winslash

Path separator to use for windows

Value

Current file directory as string

Examples

## Not run: 
getfd()

## End(Not run)
getfd(on.error = getwd())

[Package toscutil version 2.7.4 Index]