Skip to content

Preview Ruby 4.1 is a preview. It can change before the final release. Switch to Ruby 4.0 →

class method

Process.uid=

(::Integer user) -> ::Integer
Process.uid = new_uid → new_uid

Sets the (user) user ID for the current process to new_uid:

Example
Process.uid = 1000 # => 1000

Not available on all platforms.

See also .uid .wait .times .wait2 also in 4.0 · 3.4 · 3.3 · 3.2 · 3.1 · 3.0