sys-filesystem 1.5.0 → 1.5.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- checksums.yaml.gz.sig +0 -0
- data/CHANGES.md +12 -0
- data/Rakefile +5 -0
- data/lib/sys/filesystem.rb +1 -1
- data/lib/sys/unix/sys/filesystem/structs.rb +18 -5
- data/lib/sys/unix/sys/filesystem.rb +2 -5
- data/spec/sys_filesystem_shared.rb +1 -1
- data/spec/sys_filesystem_unix_spec.rb +1 -1
- data/spec/sys_filesystem_windows_spec.rb +1 -1
- data/sys-filesystem.gemspec +2 -2
- data.tar.gz.sig +0 -0
- metadata +6 -6
- metadata.gz.sig +0 -0
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 70493df8ed3722f3da6776ef9c1c287f992e9fcec64852e11b6fe04e64a7e73e
|
4
|
+
data.tar.gz: 0c924d1aca503181261bdbd1b73ed2e20eecc55293cdff2a9c8b54465859e652
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 827b599edce400ecb52221ab8d279269811f03beb9cc4440182334e5231426b75ca8b98addc10bfbdc2d1a45cc3a39ebb3d21a1f71e5f014d1053439845dd5a1
|
7
|
+
data.tar.gz: d66206e8a76a5be307c71e01a57158a49381e7699dfda4e84364dd0a44e40f8345d7a8e9e33318a6fb20f864cfbb8d86d85972d7433398cdfd510aac3e23b443
|
checksums.yaml.gz.sig
CHANGED
Binary file
|
data/CHANGES.md
CHANGED
@@ -1,3 +1,15 @@
|
|
1
|
+
## 1.5.2 - 30-Sep-2024
|
2
|
+
* Forgot to switch mkmf-lite from a dev dependency to a runtime dependency.
|
3
|
+
Thanks go to Thomas Langé for the spot and patch.
|
4
|
+
|
5
|
+
## 1.5.1 - 29-Sep-2024
|
6
|
+
* Add the f_type struct member to the Statvfs struct for Linux. This was added
|
7
|
+
at some point in the Linux lifecycle, though may still be blank depending on
|
8
|
+
your platform. Thanks go to Tasos Sahanidis for the patch.
|
9
|
+
* Added padding on 32-bit Statvfs struct with 64-bit offsets for Linux. Thanks
|
10
|
+
go Tasos Sahanidis again for this update.
|
11
|
+
* Bumped mkmf-lite dependency since the changes were needed to support the above.
|
12
|
+
|
1
13
|
## 1.5.0 - 8-Jun-2024
|
2
14
|
* Add support for DragonFlyBSD.
|
3
15
|
* Remove Solaris support. It's dead, Jim.
|
data/Rakefile
CHANGED
data/lib/sys/filesystem.rb
CHANGED
@@ -16,7 +16,7 @@ module Sys
|
|
16
16
|
# return objects of other types. Do not instantiate.
|
17
17
|
class Filesystem
|
18
18
|
# The version of the sys-filesystem library
|
19
|
-
VERSION = '1.5.
|
19
|
+
VERSION = '1.5.2'
|
20
20
|
|
21
21
|
# Stat objects are returned by the Sys::Filesystem.stat method. Here
|
22
22
|
# we're adding universal methods.
|
@@ -123,7 +123,7 @@ module Sys
|
|
123
123
|
:f_spares1, :short,
|
124
124
|
:f_mntfromname, [:char, 80],
|
125
125
|
:f_spares2, :short,
|
126
|
-
:f_spare, [:long,2]
|
126
|
+
:f_spare, [:long, 2]
|
127
127
|
)
|
128
128
|
else
|
129
129
|
layout(
|
@@ -223,10 +223,13 @@ module Sys
|
|
223
223
|
:f_unused, :int,
|
224
224
|
:f_flag, :ulong,
|
225
225
|
:f_namemax, :ulong,
|
226
|
-
:
|
226
|
+
:f_type, :uint,
|
227
|
+
:f_spare, [:int, 5]
|
227
228
|
)
|
228
229
|
else
|
229
|
-
|
230
|
+
require 'mkmf-lite'
|
231
|
+
extend Mkmf::Lite
|
232
|
+
layout_array = [
|
230
233
|
:f_bsize, :ulong,
|
231
234
|
:f_frsize, :ulong,
|
232
235
|
:f_blocks, :uint64,
|
@@ -238,8 +241,18 @@ module Sys
|
|
238
241
|
:f_fsid, :ulong,
|
239
242
|
:f_flag, :ulong,
|
240
243
|
:f_namemax, :ulong,
|
241
|
-
:
|
242
|
-
|
244
|
+
:f_type, :uint,
|
245
|
+
:f_spare, [:int, 5]
|
246
|
+
]
|
247
|
+
|
248
|
+
# Check if we need to add __f_unused
|
249
|
+
f_unused_bytes = 2 * check_sizeof('int') - check_sizeof('long')
|
250
|
+
if f_unused_bytes > 0
|
251
|
+
# For Big Endian, this should be inserted at -9
|
252
|
+
layout_array.insert(-7, :__f_unused, [:char, f_unused_bytes])
|
253
|
+
end
|
254
|
+
|
255
|
+
layout(*layout_array)
|
243
256
|
end
|
244
257
|
end
|
245
258
|
|
@@ -105,9 +105,6 @@ module Sys
|
|
105
105
|
# The filesystem type, e.g. UFS.
|
106
106
|
attr_accessor :base_type
|
107
107
|
|
108
|
-
# The filesystem ID
|
109
|
-
attr_accessor :filesystem_id
|
110
|
-
|
111
108
|
# The filesystem type
|
112
109
|
attr_accessor :filesystem_type
|
113
110
|
|
@@ -275,8 +272,8 @@ module Sys
|
|
275
272
|
if RbConfig::CONFIG['host_os'] =~ /dragonfly/i
|
276
273
|
obj.owner = fs[:f_owner]
|
277
274
|
obj.filesystem_type = fs[:f_type]
|
278
|
-
obj.sync_reads= fs[:f_syncreads]
|
279
|
-
obj.async_reads= fs[:f_asyncreads]
|
275
|
+
obj.sync_reads = fs[:f_syncreads]
|
276
|
+
obj.async_reads = fs[:f_asyncreads]
|
280
277
|
obj.sync_writes = fs[:f_syncwrites]
|
281
278
|
obj.async_writes = fs[:f_asyncwrites]
|
282
279
|
end
|
@@ -4,7 +4,7 @@ require 'sys-filesystem'
|
|
4
4
|
|
5
5
|
RSpec.shared_examples Sys::Filesystem do
|
6
6
|
example 'version number is set to the expected value' do
|
7
|
-
expect(Sys::Filesystem::VERSION).to eq('1.5.
|
7
|
+
expect(Sys::Filesystem::VERSION).to eq('1.5.2')
|
8
8
|
expect(Sys::Filesystem::VERSION).to be_frozen
|
9
9
|
end
|
10
10
|
|
@@ -10,7 +10,7 @@ require 'spec_helper'
|
|
10
10
|
require 'sys-filesystem'
|
11
11
|
require 'pathname'
|
12
12
|
|
13
|
-
RSpec.describe Sys::Filesystem, :unix
|
13
|
+
RSpec.describe Sys::Filesystem, :unix do
|
14
14
|
let(:linux) { RbConfig::CONFIG['host_os'] =~ /linux/i }
|
15
15
|
let(:bsd) { RbConfig::CONFIG['host_os'] =~ /bsd|dragonfly/i }
|
16
16
|
let(:darwin) { RbConfig::CONFIG['host_os'] =~ /mac|darwin/i }
|
data/sys-filesystem.gemspec
CHANGED
@@ -2,7 +2,7 @@ require 'rubygems'
|
|
2
2
|
|
3
3
|
Gem::Specification.new do |spec|
|
4
4
|
spec.name = 'sys-filesystem'
|
5
|
-
spec.version = '1.5.
|
5
|
+
spec.version = '1.5.2'
|
6
6
|
spec.author = 'Daniel J. Berger'
|
7
7
|
spec.email = 'djberg96@gmail.com'
|
8
8
|
spec.homepage = 'https://github.com/djberg96/sys-filesystem'
|
@@ -13,7 +13,7 @@ Gem::Specification.new do |spec|
|
|
13
13
|
spec.cert_chain = Dir['certs/*']
|
14
14
|
|
15
15
|
spec.add_dependency('ffi', '~> 1.1')
|
16
|
-
spec.
|
16
|
+
spec.add_dependency('mkmf-lite', '~> 0.7') unless Gem.win_platform?
|
17
17
|
spec.add_development_dependency('rake')
|
18
18
|
spec.add_development_dependency('rspec', '~> 3.9')
|
19
19
|
spec.add_development_dependency('rubocop')
|
data.tar.gz.sig
CHANGED
Binary file
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: sys-filesystem
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.5.
|
4
|
+
version: 1.5.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Daniel J. Berger
|
@@ -35,7 +35,7 @@ cert_chain:
|
|
35
35
|
ORVCZpRuCPpmC8qmqxUnARDArzucjaclkxjLWvCVHeFa9UP7K3Nl9oTjJNv+7/jM
|
36
36
|
WZs4eecIcUc4tKdHxcAJ0MO/Dkqq7hGaiHpwKY76wQ1+8xAh
|
37
37
|
-----END CERTIFICATE-----
|
38
|
-
date: 2024-
|
38
|
+
date: 2024-09-30 00:00:00.000000000 Z
|
39
39
|
dependencies:
|
40
40
|
- !ruby/object:Gem::Dependency
|
41
41
|
name: ffi
|
@@ -57,14 +57,14 @@ dependencies:
|
|
57
57
|
requirements:
|
58
58
|
- - "~>"
|
59
59
|
- !ruby/object:Gem::Version
|
60
|
-
version: '0.
|
61
|
-
type: :
|
60
|
+
version: '0.7'
|
61
|
+
type: :runtime
|
62
62
|
prerelease: false
|
63
63
|
version_requirements: !ruby/object:Gem::Requirement
|
64
64
|
requirements:
|
65
65
|
- - "~>"
|
66
66
|
- !ruby/object:Gem::Version
|
67
|
-
version: '0.
|
67
|
+
version: '0.7'
|
68
68
|
- !ruby/object:Gem::Dependency
|
69
69
|
name: rake
|
70
70
|
requirement: !ruby/object:Gem::Requirement
|
@@ -180,7 +180,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
180
180
|
- !ruby/object:Gem::Version
|
181
181
|
version: '0'
|
182
182
|
requirements: []
|
183
|
-
rubygems_version: 3.
|
183
|
+
rubygems_version: 3.5.16
|
184
184
|
signing_key:
|
185
185
|
specification_version: 4
|
186
186
|
summary: A Ruby interface for getting file system information.
|
metadata.gz.sig
CHANGED
Binary file
|