atk_toolbox 0.0.47 → 0.0.48
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/atk/extra_file_utils.rb +8 -8
- data/lib/atk_toolbox/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: c7be9d67722f76707b6000b6220b85b6d0d0d6edfdf693283a02febec68b9744
|
|
4
|
+
data.tar.gz: 4b8d6302134683a065feccc60ff7270f5b9a681883f53947bef66ce56c5fdbff
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: df436ca088b87354134c7c1d73b9e6a0bf610cd45b377468cfe44ba234f8e9c46d9e10bc0c234dd98ce0d1f0ee2d2b82c019d3cd262fc5ae9aa6778b8cd40a91
|
|
7
|
+
data.tar.gz: 50645c8192c39580d970e4a287710a504d279369f6558d03167d9fab88e886f324a4cc44699e10020ec4fd0cdf983777a17e3d8a15548f1c7eae1ef805471891
|
data/lib/atk/extra_file_utils.rb
CHANGED
|
@@ -69,7 +69,7 @@ class FileSys
|
|
|
69
69
|
end
|
|
70
70
|
end
|
|
71
71
|
|
|
72
|
-
def username
|
|
72
|
+
def self.username
|
|
73
73
|
if OS.is?(:windows)
|
|
74
74
|
return File.basename(ENV["userprofile"])
|
|
75
75
|
else
|
|
@@ -157,22 +157,22 @@ class FileSys
|
|
|
157
157
|
def self.glob(path)
|
|
158
158
|
Dir.glob(path, File::FNM_DOTMATCH) - %w[. ..]
|
|
159
159
|
end
|
|
160
|
-
def list_files(path=".")
|
|
160
|
+
def self.list_files(path=".")
|
|
161
161
|
Dir.children(path).select {|each| FileSys.file?(each)}
|
|
162
162
|
end
|
|
163
|
-
def list_folders(path=".")
|
|
163
|
+
def self.list_folders(path=".")
|
|
164
164
|
Dir.children(path).select {|each| FileSys.directory?(each)}
|
|
165
165
|
end
|
|
166
|
-
def ls(path)
|
|
166
|
+
def self.ls(path)
|
|
167
167
|
Dir.children(path)
|
|
168
168
|
end
|
|
169
|
-
def pwd
|
|
169
|
+
def self.pwd
|
|
170
170
|
Dir.pwd
|
|
171
171
|
end
|
|
172
|
-
def cd(path, verbose: false)
|
|
172
|
+
def self.cd(path, verbose: false)
|
|
173
173
|
FileUtils.cd(path, verbose: verbose)
|
|
174
174
|
end
|
|
175
|
-
def chdir(path, verbose: false)
|
|
175
|
+
def self.chdir(path, verbose: false)
|
|
176
176
|
FileUtils.cd(path, verbose: verbose)
|
|
177
177
|
end
|
|
178
178
|
|
|
@@ -260,7 +260,7 @@ class FileSys
|
|
|
260
260
|
File.stat(*args)
|
|
261
261
|
end
|
|
262
262
|
|
|
263
|
-
def download(input=nil, from:nil, url:nil, to:nil)
|
|
263
|
+
def self.download(input=nil, from:nil, url:nil, to:nil)
|
|
264
264
|
# if only one argument, either input or url
|
|
265
265
|
if ((input!=nil) != (url!=nil)) && (from==nil) && (to==nil)
|
|
266
266
|
# this covers:
|
data/lib/atk_toolbox/version.rb
CHANGED