Skip to content

End of Life Ruby 3.0 has reached end of life and gets no more fixes. Switch to Ruby 4.0 →

class method

Process::GID.from_name

Process::GID.from_name(name) → gid

Get the group ID by the name. If the group is not found, ArgumentError will be raised.

Example
Process::GID.from_name("wheel") #=> 0
Process::GID.from_name("nosuchgroup") #=> can't find group for nosuchgroup (ArgumentError)