dply 0.3.2 → 0.3.3

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 2a742b7e51a3fa6f6c3dde85c7e865ce808f06f4daadfdac8b9e484c0fa537dd
4
- data.tar.gz: a10e414804b13354bd1e47a78edb498aa219e43bddfdc488f4a1efdbe12e47c8
3
+ metadata.gz: 29b858fa9d36e91f13a1136c63e1ab90822a8cc06f561656de7b71d013435b3c
4
+ data.tar.gz: 9516217208aa220291ee6e882070ee4d77776e479f6acaca354e405b12235644
5
5
  SHA512:
6
- metadata.gz: 630810896801f78190c74fa7988e13308c71d388870ffcb500a9adf9d197fd1f4fe377fa5aa6339ff76274b23a3121b039c877a1664eb7167c5be00b0d1196a6
7
- data.tar.gz: 96a09128c85ba165e1f77077c402a1680a9d189116878bf7d5137500c4236d63602f633f973bf1357932bd0b3fc6ab396bd3d6d8040c9b4b49f4646f0e502035
6
+ metadata.gz: d5b2a86f4a6a98020d1ca414a22fb08758d08596a344f3f30f0639c2b4a74f977404d3bcc607be5cae6def03102802f7446af82381c7c863a81c73393ba68cde
7
+ data.tar.gz: c346852ec95ed4f55634173e78a399fa775b559911385179eac052eb92d9757f34af3cd14633a578127b40ea568e816a75a26504d024be93c85f720bdf85e0ce
@@ -47,8 +47,14 @@ module Dply
47
47
 
48
48
  def config(path, url = nil, auth: nil, deep_merge: true, optional: false, &block)
49
49
  path = "#{@dir}/#{path}"
50
- @sources << { path: path, url: url, auth: auth, deep_merge: deep_merge,
51
- optional: optional, block: block }
50
+ @sources << {
51
+ path: path,
52
+ url: url,
53
+ auth: auth,
54
+ deep_merge: deep_merge,
55
+ optional: optional,
56
+ block: block
57
+ }
52
58
  end
53
59
 
54
60
  def load_yml(path, optional:)
@@ -61,6 +67,7 @@ module Dply
61
67
 
62
68
  def download(url, path, optional:)
63
69
  logger.bullet "downloading #{url}"
70
+ FileUtils.rm(path) if File.exist?(path)
64
71
  http_status = IO.popen(["curl", "-w", '%{http_code}', "-f", "-s", "-o", @tmpfile, url]) { |f| f.read }
65
72
  exit_status = $?.exitstatus
66
73
  if (http_status != "200" || exit_status != 0)
data/lib/dply/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Dply
2
- VERSION = "0.3.2"
2
+ VERSION = "0.3.3"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dply
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.2
4
+ version: 0.3.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Neeraj
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2018-10-24 00:00:00.000000000 Z
11
+ date: 2018-10-31 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: ruby-elf