Skip to content

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

instance method

File::Stat#dev

() -> ::Integer
dev → integer

Returns the device number for the snapshot in self:

Example
File.stat('/etc').dev # => 66306
File.stat('/dev').dev # => 5
See also #ctime #dev_major #chardev? #dev_minor also in 4.0 · 3.4 · 3.3 · 3.2 · 3.1 · 3.0