pandora-frameworks 0.1.0 → 0.1.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/pandora/commands/create.rb +5 -5
- data/lib/pandora/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e4c28e7cb975c2ce09a0904d7bbb1eeac86ad3ea
|
4
|
+
data.tar.gz: 87d62ab895efa8b10754a6aedcfbe952ff069250
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 720fbc0b23a17ac317d986882874b50d77da89650b36af8c37448242edcb5520909ef139ff93f6a90be1b525c2671e6eab410852044cb36115059a34da427552
|
7
|
+
data.tar.gz: a3e67c6649c7fb39e1dd4cd2600f70d49648a5e9d405aa0557a1943e2ea6db15af78c31cc7fadd26f69646dcf7527a81715ab7bf571c222ee94fe5357f6b1ce0
|
@@ -56,7 +56,7 @@ module Pandora
|
|
56
56
|
|
57
57
|
def rename_files(path)
|
58
58
|
Dir[File.join(path, "*")].each do |file_path|
|
59
|
-
file_new_path = file_path.gsub("
|
59
|
+
file_new_path = file_path.gsub("XXXXX", @name)
|
60
60
|
FileUtils.mv file_path, file_new_path if file_path != file_new_path
|
61
61
|
if File.directory?(file_new_path)
|
62
62
|
self.rename_files(file_new_path)
|
@@ -66,11 +66,11 @@ module Pandora
|
|
66
66
|
|
67
67
|
def rename_files_content
|
68
68
|
puts "=> Renaming files content".colorize(:green)
|
69
|
-
Dir[File.join(
|
70
|
-
|
71
|
-
|
69
|
+
Dir[File.join(self.framework_path, "**/*")]
|
70
|
+
.select { |fn| !File.directory?(fn) }
|
71
|
+
.each do |file_path|
|
72
72
|
text = File.read(file_path)
|
73
|
-
new_contents = text.gsub("
|
73
|
+
new_contents = text.gsub("XXXXX", @name)
|
74
74
|
File.open(file_path, "w") {|file| file.puts new_contents }
|
75
75
|
end
|
76
76
|
puts "=> Contents renamed".colorize(:green)
|
data/lib/pandora/version.rb
CHANGED