mixlib-archive 0.4.5 → 0.4.6

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
  SHA256:
3
- metadata.gz: fc6683cb1ac7178e4fb261923f6a5c1849e2e8a73b7ab95afbb28af5e30b7496
4
- data.tar.gz: fde910fa8c62984f215bbea2b0dabc97f039d56268fc2de5b75a52b5541170a7
3
+ metadata.gz: eb6b5777f942567cd93464de95bf2acb0308fd5764476e6dc36ef60ccb859251
4
+ data.tar.gz: b16e701f76d88218b4895048763357cf962fdc12bf5912269fb379e046f66051
5
5
  SHA512:
6
- metadata.gz: d515dcc2ae6b37114e3abb384af186eab308317d5356782e6b4e48a25fa91592f4a8b6eaa4378191202ebce96d3f9d2ee853d43debd224d41ec79c20b539f3e0
7
- data.tar.gz: 515ee38251f667317dfb88d3ea4df349d8c5d640508f534e7c71628b1d3654e9e406a6a8b661dae2cd7e488eb11ec0792babb18a73d64278aa99d30649a58ab0
6
+ metadata.gz: ddb5c379da84794af3428f55dbcef397bf41dbf5d1a58fc448d9705c280f04ba7b3ae69988d028ebda70c5f75fe1259f1fdbbac708eb54c807251b0f2e9cee2d
7
+ data.tar.gz: 9b77a501440be2b107437315811ae449e6fbe7d7f1d56eb618bc657901e9b15c76a87fcfa8b04242e49402d7159582c5b68dfb193ee777d1fe06ea8071782838
data/CHANGELOG.md CHANGED
@@ -1,27 +1,32 @@
1
1
  <!-- usage documentation: http://expeditor-docs.es.chef.io/configuration/changelog/ -->
2
2
  # Change Log
3
3
 
4
- <!-- latest_release 0.4.5 -->
5
- ## [v0.4.5](https://github.com/chef/mixlib-archive/tree/v0.4.5) (2018-05-04)
4
+ <!-- latest_release 0.4.6 -->
5
+ ## [v0.4.6](https://github.com/chef/mixlib-archive/tree/v0.4.6) (2018-05-08)
6
6
 
7
7
  #### Merged Pull Requests
8
- - Fix up writing tar archives with the rubygems tar [#19](https://github.com/chef/mixlib-archive/pull/19) ([thommay](https://github.com/thommay))
8
+ - update tar magic to identify oldgnu style tar headers [#21](https://github.com/chef/mixlib-archive/pull/21) ([spion06](https://github.com/spion06))
9
9
  <!-- latest_release -->
10
10
 
11
- <!-- release_rollup since=0.4.2 -->
11
+ <!-- release_rollup since=0.4.5 -->
12
12
  ### Changes not yet released to rubygems.org
13
13
 
14
14
  #### Merged Pull Requests
15
- - Fix up writing tar archives with the rubygems tar [#19](https://github.com/chef/mixlib-archive/pull/19) ([thommay](https://github.com/thommay)) <!-- 0.4.5 -->
16
- - Fix up creating archives [#18](https://github.com/chef/mixlib-archive/pull/18) ([thommay](https://github.com/thommay)) <!-- 0.4.4 -->
15
+ - update tar magic to identify oldgnu style tar headers [#21](https://github.com/chef/mixlib-archive/pull/21) ([spion06](https://github.com/spion06)) <!-- 0.4.6 -->
17
16
  <!-- release_rollup -->
18
17
 
19
18
  <!-- latest_stable_release -->
19
+ ## [v0.4.5](https://github.com/chef/mixlib-archive/tree/v0.4.5) (2018-05-04)
20
+
21
+ #### Merged Pull Requests
22
+ - Fix up creating archives [#18](https://github.com/chef/mixlib-archive/pull/18) ([thommay](https://github.com/thommay))
23
+ - Fix up writing tar archives with the rubygems tar [#19](https://github.com/chef/mixlib-archive/pull/19) ([thommay](https://github.com/thommay))
24
+ <!-- latest_stable_release -->
25
+
20
26
  ## [v0.4.2](https://github.com/chef/mixlib-archive/tree/v0.4.2) (2018-04-25)
21
27
 
22
28
  #### Merged Pull Requests
23
29
  - use libarchive by preference [#17](https://github.com/chef/mixlib-archive/pull/17) ([thommay](https://github.com/thommay))
24
- <!-- latest_stable_release -->
25
30
 
26
31
  ## [v0.4.1](https://github.com/chef/mixlib-archive/tree/v0.4.1) (2017-02-02)
27
32
 
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.4.5
1
+ 0.4.6
@@ -118,11 +118,16 @@ module Mixlib
118
118
  end
119
119
 
120
120
  # tar's magic is at byte 257 and is "ustar\0"
121
+ # OLDGNU_MAGIC "ustar \0" /* 7 chars and a null */
121
122
  def is_tar_archive?(io)
123
+ !(read_tar_magic(io) =~ /ustar\s{0,2}\x00/).nil?
124
+ end
125
+
126
+ def read_tar_magic(io)
122
127
  io.rewind
123
- magic = io.read[257..262]
128
+ magic = io.read[257..264]
124
129
  io.rewind
125
- magic == "ustar\0"
130
+ magic
126
131
  end
127
132
 
128
133
  def reader(&block)
@@ -1,5 +1,5 @@
1
1
  module Mixlib
2
2
  class Archive
3
- VERSION = "0.4.5"
3
+ VERSION = "0.4.6"
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.4.5
4
+ version: 0.4.6
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: 2018-05-04 00:00:00.000000000 Z
11
+ date: 2018-05-08 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rake