Skip to contents

A convenient format for passing between processes, naming semaphores, or using as a directory/file name. Will always be 12 alphanumeric characters, with the first character guarantied to be a letter. Encodes the pid and creation time for a process.

Usage

ps_string(p = ps_handle())

Arguments

p

Process handle.

Value

A process string (scalar character), that can be passed to ps_handle() in place of a pid.

Examples

(p <- ps_handle())
#> <ps::ps_handle> PID=1109803, NAME=R, AT=2026-05-11 16:41:25.223517
(str <- ps_string(p))
#> [1] "eOSdaahww28m"
ps_handle(pid = str)
#> <ps::ps_handle> PID=1109803, NAME=R, AT=2026-05-11 16:41:25.223517