mixlib-archive 0.3.0 → 0.4.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 870a45eab0fb8972a29b9b78f3d2be989809d707
4
- data.tar.gz: 87b60a1d07e2e749a59f7aafae53dab2e2975abf
3
+ metadata.gz: 62781fdd21bfcd44095a2ed1c6b018f55a02f316
4
+ data.tar.gz: ca7b4a40f837192ebae44f13a53c5bd6fa2b7e91
5
5
  SHA512:
6
- metadata.gz: 5b90b2c947b8d2a5de5fb1ab97f89724cab244eb1a47bb903474a6b6eaab3448a23bd1d2d5f7847fd93377dcda29d021ef256796687953b6a90a462bef502c52
7
- data.tar.gz: d545eea24a5ebd28ff35f0f4c5646ef1838a3dce72454514fba39ca8b0abf622f36b8b86d7efffd228f6b3f582c7386dd2f9d6155e882239e9ec835b3ee4b7ef
6
+ metadata.gz: 74ed668e4a73abc0fba7c7bc2b9dc07efb41506c55c198f5df6131de0d0c74ae9f45d5e9903eb8a14a8177e9e61cdd3b01aad2d6f6b6d3f05484fee118248101
7
+ data.tar.gz: 5311c175ff2b59f0e1caf830649cb15c23070ebe8a0ed43088a22fbef0fee6ab11c53ddca6809bef2ea608025cf76ee47989af5c46c3c818cd80f3879a71a207
data/.travis.yml CHANGED
@@ -9,3 +9,4 @@ rvm:
9
9
  - 2.3.1
10
10
  before_install: gem install bundler -v 1.11.2
11
11
  script: bundle exec rake ci
12
+ bundler_args: --without changelog
data/CHANGELOG.md ADDED
@@ -0,0 +1,36 @@
1
+ # Change Log
2
+
3
+ ## [v0.4.0](https://github.com/chef/mixlib-archive/tree/v0.4.0) (2017-02-02)
4
+
5
+ [Full Changelog](https://github.com/chef/mixlib-archive/compare/v0.3.0...v0.4.0)
6
+
7
+ **Fixed bugs:**
8
+
9
+ - Ignore directory traversing file\_names in an tar [\#6](https://github.com/chef/mixlib-archive/pull/6) ([thommay](https://github.com/thommay))
10
+
11
+ ## [v0.3.0](https://github.com/chef/mixlib-archive/tree/v0.3.0) (2017-01-19)
12
+ [Full Changelog](https://github.com/chef/mixlib-archive/compare/v0.2.0...v0.3.0)
13
+
14
+ **Merged pull requests:**
15
+
16
+ - Use Rake 11 [\#5](https://github.com/chef/mixlib-archive/pull/5) ([tas50](https://github.com/tas50))
17
+ - Create archives as well as extracting them [\#4](https://github.com/chef/mixlib-archive/pull/4) ([thommay](https://github.com/thommay))
18
+
19
+ ## [v0.2.0](https://github.com/chef/mixlib-archive/tree/v0.2.0) (2016-07-05)
20
+ [Full Changelog](https://github.com/chef/mixlib-archive/compare/v0.1.0...v0.2.0)
21
+
22
+ **Merged pull requests:**
23
+
24
+ - Add logging [\#3](https://github.com/chef/mixlib-archive/pull/3) ([thommay](https://github.com/thommay))
25
+ - Make extraction safer [\#2](https://github.com/chef/mixlib-archive/pull/2) ([thommay](https://github.com/thommay))
26
+
27
+ ## [v0.1.0](https://github.com/chef/mixlib-archive/tree/v0.1.0) (2016-05-09)
28
+ [Full Changelog](https://github.com/chef/mixlib-archive/compare/053f20d5455cc463251f91d1413b973232909dc2...v0.1.0)
29
+
30
+ **Merged pull requests:**
31
+
32
+ - Turns out some tar archives don't contain dirs [\#1](https://github.com/chef/mixlib-archive/pull/1) ([thommay](https://github.com/thommay))
33
+
34
+
35
+
36
+ \* *This Change Log was automatically generated by [github_changelog_generator](https://github.com/skywinder/Github-Changelog-Generator)*
data/Gemfile CHANGED
@@ -2,3 +2,7 @@ source "https://rubygems.org"
2
2
 
3
3
  # Specify your gem's dependencies in mixlib-archive.gemspec
4
4
  gemspec
5
+
6
+ group(:changelog) do
7
+ gem "github_changelog_generator", git: "https://github.com/chef/github-changelog-generator"
8
+ end
@@ -26,6 +26,8 @@ module Mixlib
26
26
  end
27
27
 
28
28
  def extract(destination, perms: true, ignore: [])
29
+ ignore = [/^\.$/, /\.{2}/] + ignore
30
+
29
31
  create_and_empty(destination)
30
32
 
31
33
  archiver.extract(destination, perms: perms, ignore: ignore)
@@ -29,7 +29,10 @@ module Mixlib
29
29
  dest = File.join(destination, entry.read.strip)
30
30
  next
31
31
  end
32
- next if entry.full_name =~ ignore_re
32
+ if entry.full_name =~ ignore_re
33
+ Mixlib::Archive::Log.warn "ignoring entry #{entry.full_name}"
34
+ next
35
+ end
33
36
  dest ||= File.join(destination, entry.full_name)
34
37
  parent = File.dirname(dest)
35
38
  FileUtils.mkdir_p(parent)
@@ -1,5 +1,5 @@
1
1
  module Mixlib
2
2
  class Archive
3
- VERSION = "0.3.0"
3
+ VERSION = "0.4.0"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mixlib-archive
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.0
4
+ version: 0.4.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Chef Software, Inc
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-01-19 00:00:00.000000000 Z
11
+ date: 2017-02-02 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -90,6 +90,7 @@ files:
90
90
  - ".gitignore"
91
91
  - ".rspec"
92
92
  - ".travis.yml"
93
+ - CHANGELOG.md
93
94
  - Gemfile
94
95
  - LICENSE
95
96
  - README.md