rake_git_crypt 0.1.0.pre.16 → 0.1.0.pre.17
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/Gemfile.lock +1 -1
- data/lib/rake_git_crypt/tasks/add_users.rb +12 -5
- data/lib/rake_git_crypt/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: 3a748262afe405e1a15bf60aa63e213dbb2a908b7116ebb397243719dffaf138
|
|
4
|
+
data.tar.gz: 3bd972019c51aec40d6309c616b9ffeb4763384ad06dc405d073a705ba1d9274
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 214da466a7dc1e925eb425b43218fc4250328cfef808d645a55a128dc19a0c0632c4393d267cfea407b996dd45b0731cdcad7f4c6a3a8aef2809c140290089ce
|
|
7
|
+
data.tar.gz: 90d8d68012f680583f37ba842f36176d7a83d3226ec8f088a5d5a85f68a0d47575fc4133b4cf66525a4abbb5fb07a137a24c2cfec253ffc53f3791f7014597ed
|
data/Gemfile.lock
CHANGED
|
@@ -36,9 +36,12 @@ module RakeGitCrypt
|
|
|
36
36
|
private
|
|
37
37
|
|
|
38
38
|
def gpg_user_key_paths
|
|
39
|
-
|
|
39
|
+
parameter = self.class.parameter_set.find(:gpg_user_key_paths)
|
|
40
|
+
key_paths = parameter.get(self)
|
|
40
41
|
|
|
41
|
-
|
|
42
|
+
return nil if key_paths.nil?
|
|
43
|
+
|
|
44
|
+
resolve_key_paths(key_paths)
|
|
42
45
|
end
|
|
43
46
|
|
|
44
47
|
def resolve_key_paths(paths)
|
|
@@ -51,14 +54,18 @@ module RakeGitCrypt
|
|
|
51
54
|
if File.file?(path)
|
|
52
55
|
[path]
|
|
53
56
|
elsif File.directory?(path)
|
|
54
|
-
resolve_key_paths(
|
|
55
|
-
Dir.entries(path).reject { |entry| %w[. ..].include?(entry) }
|
|
56
|
-
)
|
|
57
|
+
resolve_key_paths(list_directory(path))
|
|
57
58
|
else
|
|
58
59
|
[]
|
|
59
60
|
end
|
|
60
61
|
end
|
|
61
62
|
|
|
63
|
+
def list_directory(path)
|
|
64
|
+
Dir.entries(path)
|
|
65
|
+
.reject { |entry| %w[. ..].include?(entry) }
|
|
66
|
+
.map { |entry| File.join(path, entry) }
|
|
67
|
+
end
|
|
68
|
+
|
|
62
69
|
def ensure_users_provided
|
|
63
70
|
if gpg_user_details_present?(:key_path) ||
|
|
64
71
|
gpg_user_details_present?(:id)
|