cocoapods-localzedLoader 0.1.9 → 0.2.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
  SHA256:
3
- metadata.gz: 12e20670e8b6a34ee41901ed75f366056badd7fcda4f1cc655e03a15db9bcdb9
4
- data.tar.gz: 15e6ce7c2a104e370590b77d97f5655e5d4a6e8d710793035fe3a2bdc100b6ce
3
+ metadata.gz: 6ad0d7282a9174ab511426a98b265573e976355cf155352027781a9a15726ec4
4
+ data.tar.gz: 78c4d779fffb4b35ee48350d4538171384982351edd1f40e09d8e864aa384d48
5
5
  SHA512:
6
- metadata.gz: 8c4682838148e67c717abefb89f1470627b83221b048b3cc77d1dce88e3fa649d185f935c87c5d3f795e0b96b633c3e9d698f92f5694bb9de95c9d719a8490b8
7
- data.tar.gz: cb99d09ef4193662e80317b1994a6c6d1d8b2972425e62938a91d77e16ba75ba54d5f990069d8ee183b61dac28608bd948675bc4edd59ad36be913bc37d5d9a2
6
+ metadata.gz: ae961dc62b9f9c019270867bb69dae020ab395cbe568e7b01fba7b8474252a9c337a2ffbdea59384fb61d078f4caf00a4740f7c1f86145438504ecad89e6f25e
7
+ data.tar.gz: 5dd20aaf94317fe771f41567e69c71ab57e111bd59284da49cb546ae628d15ceedce78e704de0a284416be9aeb02f6a719005b334afe2b081770d0fb58278fc6
@@ -1,3 +1,3 @@
1
1
  module Localizedloader
2
- VERSION = "0.1.9"
2
+ VERSION = "0.2.0"
3
3
  end
@@ -28,6 +28,9 @@ class BundleGenerater
28
28
  dir = File.dirname localized_file
29
29
  FileUtils.rm_rf localized_file
30
30
  FileUtils.mkdir_p dir
31
+ new_file = File.new(localized_file, "w")
32
+ new_file.close
33
+
31
34
  end
32
35
 
33
36
  #生成资源文件
@@ -45,8 +48,11 @@ class BundleGenerater
45
48
  end
46
49
  str = %Q|"#{key}" = "#{value}";\n|
47
50
  localized_file = "./#{lang}.lproj/Localizable.strings"
48
- File.open(localized_file, "a") do |io|
49
- io.write str
51
+
52
+ if File.exist?(localized_file)
53
+ File.open(localized_file, "a") do |io|
54
+ io.write str
55
+ end
50
56
  end
51
57
 
52
58
  #如果是infoplist里的key,就写入指定的文件
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cocoapods-localzedLoader
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.9
4
+ version: 0.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - jeremylu
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-01-24 00:00:00.000000000 Z
11
+ date: 2024-04-16 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: httparty