xcodeproj 0.5.3 → 0.5.4
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.
- data/lib/xcodeproj/project.rb +8 -7
- data/lib/xcodeproj.rb +1 -1
- metadata +2 -2
data/lib/xcodeproj/project.rb
CHANGED
@@ -272,16 +272,17 @@ module Xcodeproj
|
|
272
272
|
#
|
273
273
|
# @return [void]
|
274
274
|
#
|
275
|
-
def fix_encoding(
|
276
|
-
|
277
|
-
File.
|
278
|
-
|
279
|
-
|
275
|
+
def fix_encoding(filename)
|
276
|
+
output = ''
|
277
|
+
input = File.open(filename, 'rb') { |file| file.read }
|
278
|
+
input.unpack('U*').each do |codepoint|
|
279
|
+
if codepoint > 127
|
280
|
+
output << "&##{codepoint};"
|
280
281
|
else
|
281
|
-
|
282
|
+
output << codepoint.chr
|
282
283
|
end
|
283
284
|
end
|
284
|
-
File.open(
|
285
|
+
File.open(filename, 'wb') { |file| file.write(output) }
|
285
286
|
end
|
286
287
|
|
287
288
|
#-------------------------------------------------------------------------#
|
data/lib/xcodeproj.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: xcodeproj
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.5.
|
4
|
+
version: 0.5.4
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2013-04-
|
12
|
+
date: 2013-04-04 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: activesupport
|