cpee-resources 1.0.0 → 1.0.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/cpee-resources.gemspec +1 -1
- data/tools/cpee-resources +15 -11
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 7c92683f7ab22dc0df755e682c252413fa11bea895c714aec38709d36bff6b49
|
4
|
+
data.tar.gz: 313953754f94d95d4cccc8f39369f0a8c1a1eb0d848072b54e005a443256bddb
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a55bbb3a98061c299f00e5febabbc090358d0fab751f52c95671f001bee7e793ba3dba559cb82d1d11d8ecb78a305350cc2f518fd21a3ed484f276f591a005bb
|
7
|
+
data.tar.gz: 62917c79aac0df5fc636e6559427ddd5df45558063c990c34640edca68d57aead216eb7e3b5dcf009d68b6928ef468b8d3a66dc644b6248e46e2dcd9ee72099e
|
data/cpee-resources.gemspec
CHANGED
data/tools/cpee-resources
CHANGED
@@ -43,24 +43,28 @@ end
|
|
43
43
|
ARGV.options { |opt|
|
44
44
|
opt.summary_indent = ' ' * 2
|
45
45
|
opt.summary_width = 15
|
46
|
-
opt.banner = "Usage:\n#{opt.summary_indent}#{File.basename($0)} [DIR
|
46
|
+
opt.banner = "Usage:\n#{opt.summary_indent}#{File.basename($0)} [options] new DIR\n"
|
47
47
|
opt.on("Options:")
|
48
48
|
opt.on("--help", "-h", "This text") { puts opt; exit }
|
49
49
|
opt.on("")
|
50
|
-
opt.on(wrap("[DIR]
|
50
|
+
opt.on(wrap("[new DIR] scaffolds a sample resources service."))
|
51
51
|
opt.parse!
|
52
52
|
}
|
53
|
-
if (ARGV.length
|
53
|
+
if (ARGV.length < 2) ||
|
54
|
+
(ARGV.length == 2 && !(%w(new).include?(ARGV[0]))) ||
|
55
|
+
(ARGV.length > 2)
|
54
56
|
puts ARGV.options
|
55
57
|
exit
|
56
|
-
else
|
57
|
-
p1 = ARGV[0]
|
58
58
|
end
|
59
|
+
command = ARGV[0]
|
60
|
+
p1 = ARGV[1]
|
59
61
|
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
62
|
+
if command == 'new'
|
63
|
+
insta = "#{curpath}/../server/"
|
64
|
+
if !File.exist?(p1)
|
65
|
+
FileUtils.cp_r(insta,p1)
|
66
|
+
else
|
67
|
+
FileUtils.cp_r(Dir.glob(File.join(insta,'*')).delete_if{|e| e =~ /\.conf/ },p1,remove_destination: true)
|
68
|
+
puts 'Directory already exists, updating ...'
|
69
|
+
end
|
66
70
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: cpee-resources
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Juergen eTM Mangler
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: tools
|
11
11
|
cert_chain: []
|
12
|
-
date: 2024-
|
12
|
+
date: 2024-07-02 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: riddl
|