rxfreadwrite 0.1.5 → 0.2.0
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/lib/rxfreadwrite.rb +29 -3
- data.tar.gz.sig +0 -0
- metadata +24 -4
- 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: 5ce3e2d94948e994649b37b42b231ff4a153b9966b34df1a52b5a4ab384dfe15
|
4
|
+
data.tar.gz: 62b36ab4f5b3a394ad8e022c5bea9cc6f6457411858c4d370c5653a14c6c6977
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a37ea0d264edf3531b18e335b693d6e452d7f7a492e97dbf94211a321a751c53ed9b1880ebc1366fceb1992934e710ba8a733f7bc444675e5c9a6f3ae15a1a01
|
7
|
+
data.tar.gz: fe40d75490bdab065e8146f1de7e60a0b0b0f8c9c636f9bf22cbe80777d013e97a56dec7062a8d223bba4339a2a44d934d0e6d628917dabab7bd12a4ed6f0060
|
checksums.yaml.gz.sig
CHANGED
Binary file
|
data/lib/rxfreadwrite.rb
CHANGED
@@ -3,6 +3,7 @@
|
|
3
3
|
# file: rxfreadwrite.rb
|
4
4
|
|
5
5
|
require 'rxfreader'
|
6
|
+
require 'drb_fileclient-readwrite'
|
6
7
|
|
7
8
|
|
8
9
|
module RXFReadWriteModule
|
@@ -10,15 +11,17 @@ module RXFReadWriteModule
|
|
10
11
|
|
11
12
|
class DirX
|
12
13
|
|
14
|
+
def self.chdir(s) RXFReadWrite.chdir(s) end
|
13
15
|
def self.glob(s) RXFReadWrite.glob(s) end
|
14
16
|
def self.mkdir(s) RXFReadWrite.mkdir(s) end
|
15
17
|
def self.mkdir_p(s) RXFReadWrite.mkdir_p(s) end
|
16
18
|
|
17
19
|
end
|
18
20
|
|
19
|
-
def FileX.
|
20
|
-
def FileX.
|
21
|
-
def FileX.
|
21
|
+
def FileX.chdir(s) RXFReadWrite.chdir(s) end
|
22
|
+
def FileX.mkdir(s) RXFReadWrite.mkdir(s) end
|
23
|
+
def FileX.mkdir_p(s) RXFReadWrite.mkdir_p(s) end
|
24
|
+
def FileX.rm(s) RXFReadWrite.rm(s) end
|
22
25
|
|
23
26
|
def FileX.rm_r(s, force: false)
|
24
27
|
RXFReadWrite.rm_r(s, force: force)
|
@@ -40,6 +43,29 @@ end
|
|
40
43
|
class RXFReadWrite < RXFReader
|
41
44
|
using ColouredText
|
42
45
|
|
46
|
+
|
47
|
+
def self.chdir(x)
|
48
|
+
|
49
|
+
# We can use @fs within chdir() to flag the current file system.
|
50
|
+
# Allowing us to use relative paths with FileX operations instead
|
51
|
+
# of explicitly stating the path each time. e.g. touch 'foo.txt'
|
52
|
+
#
|
53
|
+
|
54
|
+
if x[/^file:\/\//] or File.exists?(File.dirname(x)) then
|
55
|
+
|
56
|
+
@fs = :local
|
57
|
+
FileUtils.chdir x
|
58
|
+
|
59
|
+
elsif x[/^dfs:\/\//]
|
60
|
+
|
61
|
+
host = x[/(?<=dfs:\/\/)[^\/]+/]
|
62
|
+
@fs = 'dfs://' + host
|
63
|
+
DfsFile.chdir x
|
64
|
+
|
65
|
+
end
|
66
|
+
|
67
|
+
end
|
68
|
+
|
43
69
|
def self.glob(s)
|
44
70
|
|
45
71
|
if s[/^dfs:\/\//] then
|
data.tar.gz.sig
CHANGED
Binary file
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rxfreadwrite
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- James Robertson
|
@@ -35,10 +35,30 @@ cert_chain:
|
|
35
35
|
gnYmJHVhKvNaFwL4ryulhkA+n8o3Ve6Kzo/AGlO2+Ge6H0bqIUbS8UisqDa7IwlY
|
36
36
|
tvleW582+lzMrpAfWdGb4VFX
|
37
37
|
-----END CERTIFICATE-----
|
38
|
-
date: 2022-02-
|
38
|
+
date: 2022-02-22 00:00:00.000000000 Z
|
39
39
|
dependencies:
|
40
40
|
- !ruby/object:Gem::Dependency
|
41
41
|
name: rxfreader
|
42
|
+
requirement: !ruby/object:Gem::Requirement
|
43
|
+
requirements:
|
44
|
+
- - "~>"
|
45
|
+
- !ruby/object:Gem::Version
|
46
|
+
version: '0.2'
|
47
|
+
- - ">="
|
48
|
+
- !ruby/object:Gem::Version
|
49
|
+
version: 0.2.1
|
50
|
+
type: :runtime
|
51
|
+
prerelease: false
|
52
|
+
version_requirements: !ruby/object:Gem::Requirement
|
53
|
+
requirements:
|
54
|
+
- - "~>"
|
55
|
+
- !ruby/object:Gem::Version
|
56
|
+
version: '0.2'
|
57
|
+
- - ">="
|
58
|
+
- !ruby/object:Gem::Version
|
59
|
+
version: 0.2.1
|
60
|
+
- !ruby/object:Gem::Dependency
|
61
|
+
name: drb_fileclient-readwrite
|
42
62
|
requirement: !ruby/object:Gem::Requirement
|
43
63
|
requirements:
|
44
64
|
- - "~>"
|
@@ -46,7 +66,7 @@ dependencies:
|
|
46
66
|
version: '0.1'
|
47
67
|
- - ">="
|
48
68
|
- !ruby/object:Gem::Version
|
49
|
-
version: 0.1.
|
69
|
+
version: 0.1.0
|
50
70
|
type: :runtime
|
51
71
|
prerelease: false
|
52
72
|
version_requirements: !ruby/object:Gem::Requirement
|
@@ -56,7 +76,7 @@ dependencies:
|
|
56
76
|
version: '0.1'
|
57
77
|
- - ">="
|
58
78
|
- !ruby/object:Gem::Version
|
59
|
-
version: 0.1.
|
79
|
+
version: 0.1.0
|
60
80
|
description:
|
61
81
|
email: digital.robertson@gmail.com
|
62
82
|
executables: []
|
metadata.gz.sig
CHANGED
Binary file
|