dev 2.0.294 → 2.0.295
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/base/environment.rb +10 -6
- data/lib/tasks/publish.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: c6666ffa82ab4132b61c700cbfab6e441563c76b
|
4
|
+
data.tar.gz: 0a1bfe238f8bb764411269a051b14daf97550f2f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 23727c1335651ca6550384e0ea12c4263b7faeb8ca14020d8b3d80a077cad66236724ffe003a80b2da2fc76346bcd77316a8841d8ff05d94ef43ecf75b4e9583
|
7
|
+
data.tar.gz: 52dcdbaa5f04e573d2ebf4dd76430389b1e46f105a6c0b6d818e070bdc632160128c84a7a3b7b95c3b06f0c4b39fdd3090c2c2cd0f5c3cc0908f719ae3c64883
|
data/lib/base/environment.rb
CHANGED
@@ -3,7 +3,7 @@ puts __FILE__ if defined?(DEBUG)
|
|
3
3
|
require_relative('string.rb')
|
4
4
|
|
5
5
|
class Environment < Hash
|
6
|
-
attr_accessor :output
|
6
|
+
attr_accessor :output,:publish_dir
|
7
7
|
@@default=nil
|
8
8
|
def self.default
|
9
9
|
@@default=Environment.new if @@default.nil?
|
@@ -12,6 +12,7 @@ class Environment < Hash
|
|
12
12
|
|
13
13
|
def initialize env=nil
|
14
14
|
@output=''
|
15
|
+
|
15
16
|
@env=Hash.new
|
16
17
|
@env_aliases={'HOME' => ['USERPROFILE'],
|
17
18
|
'DEV_ROOT' => ['DEV_HOME','HOME','USERPROFILE'],
|
@@ -19,6 +20,9 @@ class Environment < Hash
|
|
19
20
|
}
|
20
21
|
env.each{|k,v| @env[k.to_s]=v} if !env.nil?
|
21
22
|
@@default=self if @@default.nil?
|
23
|
+
|
24
|
+
@publish_dir="#{root_dir}/publish"
|
25
|
+
FileUtils.mkdir_p @publish_dir if !File.exists? @publish_dir
|
22
26
|
end
|
23
27
|
|
24
28
|
#####Begin LEGACY support
|
@@ -53,11 +57,11 @@ class Environment < Hash
|
|
53
57
|
dir
|
54
58
|
end
|
55
59
|
|
56
|
-
def publish_dir
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
end
|
60
|
+
#def publish_dir
|
61
|
+
# dir="#{root_dir}/publish"
|
62
|
+
# FileUtils.mkdir_p dir if !File.exists? dir
|
63
|
+
# dir
|
64
|
+
#end
|
61
65
|
|
62
66
|
def wrk_dir
|
63
67
|
dir="#{root_dir}/wrk"
|
data/lib/tasks/publish.rb
CHANGED
@@ -28,7 +28,7 @@ class Publish < Array
|
|
28
28
|
|
29
29
|
Dir.glob("#{Rake.application.original_dir}/**/*.{nupkg,msi,gem}").each{|publish_file|
|
30
30
|
dest="#{Environment.default.publish_dir}/#{File.basename(publish_file)}"
|
31
|
-
add_quiet "<%FileUtils.cp('#{publish_file}','#{dest}')%>" if(!File.exists?(dest)
|
31
|
+
add_quiet "<%FileUtils.cp('#{publish_file}','#{dest}')%>" if(!File.exists?(dest) && !publish_file.include?('packages/'))
|
32
32
|
}
|
33
33
|
end
|
34
34
|
end
|