hoodie 0.2.3 → 0.2.4

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: d3fbd4e06e18bd026b0223686979c6369898de0c
4
- data.tar.gz: 3777b3d7511d135c0151c696c85b5b2b2de9a6ce
3
+ metadata.gz: 02c7f5949654025049f5d31b44a053e391cf1acc
4
+ data.tar.gz: 715bc9fb1518e1c2fd90e591c86c8843b159bd09
5
5
  SHA512:
6
- metadata.gz: 537ec0ba826f8aca73646d2e672ccac7147f1f948375c7c34de0e65d285d58068f6d7a63c87f568c6ccfcf5bc74811f3aa2aa9fa1f7f15d3d901d7263b0ebb53
7
- data.tar.gz: 4d4ab331c810c77964274470c4f4a8cc207e204627426b2fe44e3335005d7870765243388e8bf7864f267ec36289d9c73c89379477815d549794742a71d248e1
6
+ metadata.gz: 85bdc00b8e353643a669a33ff04987485ac46e85a98d9bd2ed36a085c8dee73686a62eb54bfd16e196952ff942004b914e33042d2068954c8010f6a47875c415
7
+ data.tar.gz: 98c1dd4c8ddca703a965319d6477c7dd8c4a06bb8506b17aa0e4bdd38d4fe478144276c7882fc4f184d0d34a6a0b2b6371f0ecf10fa4ad8612732ff3c24f4e29
@@ -12,8 +12,8 @@
12
12
  #
13
13
  # Unless required by applicable law or agreed to in writing, software
14
14
  # distributed under the License is distributed on an "AS IS" BASIS,
15
- # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
16
- # implied. See the License for the specific language governing
15
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
16
+ # implied. See the License for the specific language governing
17
17
  # permissions and limitations under the License.
18
18
  #
19
19
 
@@ -103,12 +103,10 @@ module DiskStash
103
103
  # temp path. On Winders Dir.tmpdir returns the correct path.
104
104
  #
105
105
  def file_store
106
- # tmp = defined?(Chef::Config) ? Chef::Config[:file_cache_path] : Dir.tmpdir
107
106
  if OS.windows?
108
- win_friendly_path('/windows/system32/drivers/._stash_')
107
+ win_friendly_path('/chef/._stash_')
109
108
  else
110
- '_stash'
111
- # ::File.join(tmp, '._stash')
109
+ ::File.join('var', 'lib', '._stash')
112
110
  end
113
111
  end
114
112
 
@@ -122,7 +120,7 @@ module DiskStash
122
120
  end
123
121
 
124
122
  def _write_cache_file(key, content)
125
- f = ::File.open(cache_file(key), 'w+' )
123
+ f = ::File.open(cache_file(key), 'wb' )
126
124
  f.flock(::File::LOCK_EX)
127
125
  f.write(content)
128
126
  f.close
@@ -130,7 +128,7 @@ module DiskStash
130
128
  end
131
129
 
132
130
  def _read_cache_file(key)
133
- f = ::File.open(cache_file(key), 'r')
131
+ f = ::File.open(cache_file(key), 'rb')
134
132
  f.flock(::File::LOCK_SH)
135
133
  out = f.read
136
134
  f.close
@@ -18,5 +18,5 @@
18
18
  #
19
19
 
20
20
  module Hoodie
21
- VERSION = '0.2.3'
21
+ VERSION = '0.2.4'
22
22
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: hoodie
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.3
4
+ version: 0.2.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Stefano Harding