settmpdir: Temporarily set a path to a specific directory. Path is...

View source: R/utils.r

settmpdirR Documentation

Temporarily set a path to a specific directory. Path is restored once the calling function/frame ends.

Description

Temporarily set a path to a specific directory. Path is restored once the calling function/frame ends.

Usage

settmpdir(dir)

Arguments

dir

directory

Examples

dir = tempdir()
test = function(){
    beter:::settmpdir(dir)
    print(getwd())
    }
test() # should print dir
print(getwd()) # back to normal


bioDS/beter documentation built on June 15, 2022, 7:58 a.m.