fastlane-plugin-google_sheet_localize 0.1.95 → 0.1.97

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 001f36a850ddf5a17f24493f71aa2832e46c9579cc2e570daa4f9401d0f03f4b
4
- data.tar.gz: dd9ff3ebf25845ec19d88968471662e3552ef6b2c522b974b2184cdd7627cddf
3
+ metadata.gz: 64df7e5b0d08bae88d1d6471d1e30f19b4abea6e8e2aac558c0973128fb3ef3e
4
+ data.tar.gz: a6c480e9dfb078b2955e5f20cd041d0f81294c3502e9a780bbc0b7b9de55a052
5
5
  SHA512:
6
- metadata.gz: b5f694c17d7390b5d3f587c5c1536a9cfb262142281d6846e1f6d263ec4cf784e15e9c3a81615698e6de3eb3aad81845519ad877ea3e3082cd63a017fa07853b
7
- data.tar.gz: ff346a2ed95706dcd1034346b0519fef831d2a664ccd7b5f2ed85e1960202e0fa4498aaff89db2e506e8c97c661662a9f5a68b16f97924519522e6646e9fdc7f
6
+ metadata.gz: c2a6106f1d1383f08b6ff8a44b7fbda0f12a1afa18481723f68814a321d90e41061b0644edd8353fdc6b7dc648fbcaab7a552a0739ce88abf39dece0e7600456
7
+ data.tar.gz: ad52ac0c8681db4970ff5d40b13175ab2290dc23188b9c06c390561ba7e781c2d38c7b9db62ba878012b85eee766e317aca5dd281b66271c487ec6a9927ac46d
@@ -228,11 +228,13 @@ module Fastlane
228
228
 
229
229
  text = text.gsub("\n", "|")
230
230
 
231
+ formatIdentifier = identifier.gsub(".", "")
232
+
231
233
  f.write("\t\t<key>#{identifier}</key>\n")
232
234
  f.write("\t\t<dict>\n")
233
235
  f.write("\t\t\t<key>NSStringLocalizedFormatKey</key>\n")
234
- f.write("\t\t\t<string>%#@#{identifier}@</string>\n")
235
- f.write("\t\t\t<key>#{identifier}</key>\n")
236
+ f.write("\t\t\t<string>%#@#{formatIdentifier}@</string>\n")
237
+ f.write("\t\t\t<key>#{formatIdentifier}</key>\n")
236
238
  f.write("\t\t\t<dict>\n")
237
239
  f.write("\t\t\t\t<key>NSStringFormatSpecTypeKey</key>\n")
238
240
  f.write("\t\t\t\t<string>NSStringPluralRuleType</string>\n")
@@ -326,7 +328,7 @@ module Fastlane
326
328
  end
327
329
 
328
330
  def self.createiOSFileEndString()
329
- return "\n\nprivate class LocalizationHelper { }\n\nextension Localization {\n\tprivate static func localized(identifier key: String, _ args: CVarArg...) -> String {\n\t\tlet format = NSLocalizedString(key, tableName: nil, bundle: Bundle(for: LocalizationHelper.self), comment: \"\")\n\n\t\tguard !args.isEmpty else { return format }\n\n\t\treturn String.localizedStringWithFormat(format, args)\n\t}\n}"
331
+ return "\n\nprivate class LocalizationHelper { }\n\nextension Localization {\n\tprivate static func localized(identifier key: String, _ args: CVarArg...) -> String {\n\t\tlet format = NSLocalizedString(key, tableName: nil, bundle: Bundle(for: LocalizationHelper.self), comment: \"\")\n\n\t\tguard !args.isEmpty else { return format }\nif args.count == 1, let first = args.first {\n\t\t\treturn String.localizedStringWithFormat(format, first)\n\t\treturn String.localizedStringWithFormat(format, args)\n\t}\n}"
330
332
  end
331
333
 
332
334
  def self.createiOSFunction(constantName, identifier, arguments, comment)
@@ -429,7 +431,8 @@ module Fastlane
429
431
  FastlaneCore::ConfigItem.new(key: :tabs,
430
432
  env_name: "TABS",
431
433
  description: "Array of all Google Sheet Tabs",
432
- optional: false,
434
+ default_value: [],
435
+ optional: true,
433
436
  type: Array),
434
437
  FastlaneCore::ConfigItem.new(key: :language_titles,
435
438
  env_name: "LANGUAGE_TITLES",
@@ -1,5 +1,5 @@
1
1
  module Fastlane
2
2
  module GoogleSheetLocalize
3
- VERSION = "0.1.95"
3
+ VERSION = "0.1.97"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fastlane-plugin-google_sheet_localize
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.95
4
+ version: 0.1.97
5
5
  platform: ruby
6
6
  authors:
7
7
  - Mario Hahn
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-02-07 00:00:00.000000000 Z
11
+ date: 2019-02-08 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: google_drive