Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

ps_open_files

Open files of a process


Description

Note that in some IDEs, e.g. RStudio or R.app on macOS, the IDE itself opens files from other threads, in addition to the files opened from the main R thread.

Usage

ps_open_files(p = ps_handle())

Arguments

p

Process handle.

Details

For a zombie process it throws a zombie_process error.

Value

Data frame, or tibble if the tibble package is available, with columns: fd and path. fd is numeric file descriptor on POSIX systems, NA on Windows. path is an absolute path to the file.

See Also

Examples

p <- ps_handle()
ps_open_files(p)
f <- file(tmp <- tempfile(), "w")
ps_open_files(p)
close(f)
unlink(tmp)
ps_open_files(p)

ps

List, Query, Manipulate System Processes

v1.6.0
MIT + file LICENSE
Authors
Jay Loden [aut], Dave Daeschler [aut], Giampaolo Rodola' [aut], Gábor Csárdi [aut, cre], RStudio [cph]
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.