plist 3.7.0 → 3.7.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/plist/generator.rb +2 -4
- data/lib/plist/parser.rb +3 -3
- data/lib/plist/version.rb +1 -1
- data/lib/plist.rb +0 -1
- metadata +3 -7
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 0c9c26542d33281fc5129c6e41bf1fb50cd6bc18e976026a99a0f5e1227422a4
|
4
|
+
data.tar.gz: 0a3e7e39de4ee273ab12239e9577166bace1e7fd244b479253d215b373da324a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f8604a0b065dbcbdaeaac185f69846f9b98bfa001988bf0e33cda3376a1f8ad07956df89a53bbda3e894f71003293d572fa6a9224f0bd4371a50fa075363b152
|
7
|
+
data.tar.gz: 61e3bee01b0f7afc798743e7b064244a76d8de4a18621e9dde388fe066bcc9428171e76f4b91ea28925f9c988d7cefbcb8d708547701c45a92274ed71949bf4e
|
data/lib/plist/generator.rb
CHANGED
@@ -124,11 +124,9 @@ module Plist
|
|
124
124
|
|
125
125
|
def data_tag(data, level)
|
126
126
|
# note that apple plists are wrapped at a different length then
|
127
|
-
# what ruby's
|
128
|
-
# I used #encode64 instead of #b64encode (which allows a length arg)
|
129
|
-
# because b64encode is b0rked and ignores the length arg.
|
127
|
+
# what ruby's pack wraps by default.
|
130
128
|
tag('data', nil, level) do
|
131
|
-
Base64.encode64(data)
|
129
|
+
[data].pack("m") # equivalent to Base64.encode64(data)
|
132
130
|
.gsub(/\s+/, '')
|
133
131
|
.scan(/.{1,68}/o)
|
134
132
|
.collect { |line| indent(line, level) }
|
data/lib/plist/parser.rb
CHANGED
@@ -56,7 +56,7 @@ module Plist
|
|
56
56
|
|
57
57
|
def text(contents)
|
58
58
|
if @open.last
|
59
|
-
@open.last.text ||= ''
|
59
|
+
@open.last.text ||= ''.dup
|
60
60
|
@open.last.text.concat(contents)
|
61
61
|
end
|
62
62
|
end
|
@@ -246,10 +246,10 @@ module Plist
|
|
246
246
|
end
|
247
247
|
end
|
248
248
|
|
249
|
-
require 'base64'
|
250
249
|
class PData < PTag
|
251
250
|
def to_ruby
|
252
|
-
|
251
|
+
# unpack("m")[0] is equivalent to Base64.decode64
|
252
|
+
data = text.gsub(/\s+/, '').unpack("m")[0] unless text.nil?
|
253
253
|
begin
|
254
254
|
return Marshal.load(data) if options[:marshal]
|
255
255
|
rescue Exception
|
data/lib/plist/version.rb
CHANGED
data/lib/plist.rb
CHANGED
metadata
CHANGED
@@ -1,20 +1,18 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: plist
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 3.7.
|
4
|
+
version: 3.7.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ben Bleything
|
8
8
|
- Patrick May
|
9
|
-
autorequire:
|
10
9
|
bindir: bin
|
11
10
|
cert_chain: []
|
12
|
-
date:
|
11
|
+
date: 2024-12-26 00:00:00.000000000 Z
|
13
12
|
dependencies: []
|
14
13
|
description: Plist is a library to manipulate Property List files, also known as plists.
|
15
14
|
It can parse plist files into native Ruby data structures as well as generating
|
16
15
|
new plist files from your Ruby objects.
|
17
|
-
email:
|
18
16
|
executables: []
|
19
17
|
extensions: []
|
20
18
|
extra_rdoc_files: []
|
@@ -28,7 +26,6 @@ homepage: https://github.com/patsplat/plist
|
|
28
26
|
licenses:
|
29
27
|
- MIT
|
30
28
|
metadata: {}
|
31
|
-
post_install_message:
|
32
29
|
rdoc_options: []
|
33
30
|
require_paths:
|
34
31
|
- lib
|
@@ -43,8 +40,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
43
40
|
- !ruby/object:Gem::Version
|
44
41
|
version: '0'
|
45
42
|
requirements: []
|
46
|
-
rubygems_version: 3.
|
47
|
-
signing_key:
|
43
|
+
rubygems_version: 3.6.2
|
48
44
|
specification_version: 4
|
49
45
|
summary: All-purpose Property List manipulation library
|
50
46
|
test_files: []
|