gonative-cli 1.3.6 → 1.3.8

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: 0b8750e6f8ce04f30fa5de7a9d9b33c26383db072687e6e0df1c989eb803d6d1
4
- data.tar.gz: dc9cff9b0d587eb192a6e72050c089df4345bb8b210caf733ff9f8881f07c6bf
3
+ metadata.gz: 072f9e786f31e758f24a6680f91bcec7303990eb5c78d58fd3fd54acef04d015
4
+ data.tar.gz: 4bd8ae73721d0dd614cd161b3a6b86715fe5fc371a3361eb7d871a3e0b40f9e2
5
5
  SHA512:
6
- metadata.gz: ae9a9eb0dbcf1f247ca78071fd83dc66f5569f29b3389fdab21bbf0388f602f273f0e672275c4bcd7c3993ea879f34d778e70200edc7f3f287a1070de6f1866d
7
- data.tar.gz: 7f3e36fb8db7180f05c38a6851d7959baec4021eb697b5868669df6fdea6d942ebfd8a63cdb0b082ddd9f0b0034c278e79e0e806722bb9a02c2ca13c51655864
6
+ metadata.gz: 9bdb027fe9bd03782c16012fbf596d14b6090d7ac6e0d0d42088fb29a74beedaccf46cdf041aebd56794f14c8efbfa88adbc73ef3f677f73c461c9157e7ed2d5
7
+ data.tar.gz: ba970e1b131a3403231c8b8e79f31c32df160336b1b4a7c0e29afb18cc807f152a4e314c2b75684a6163cb231fdf84983662aea40a35a559929f0f837b2fac23
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- gonative-cli (1.3.6)
4
+ gonative-cli (1.3.7)
5
5
  activesupport (~> 6.0)
6
6
  cocoapods (~> 1.10)
7
7
  colorize (~> 0.8.0)
@@ -15,13 +15,31 @@ module GoNative
15
15
  end
16
16
 
17
17
  def call
18
+ return unless exists?
19
+
18
20
  proj = Xcodeproj::Project.open('MedianIOS.xcodeproj')
19
- file = proj.new_file("#{language}.lproj")
20
- file.move(proj.groups.first)
21
- proj.targets.first.add_resources([file])
22
-
21
+ file = proj.new_file("#{language}.lproj/Localizable.strings")
22
+ file.move(localizable_group(proj))
23
+ file.name = language
24
+
23
25
  proj.save
24
26
  end
27
+
28
+ def localizable_group(proj)
29
+ proj.objects.each do |o|
30
+ if o.is_a?(Xcodeproj::Project::Object::PBXGroup) && (o.hierarchy_path == '/LeanIOS/Localizable.strings')
31
+ return o
32
+ end
33
+ end
34
+
35
+ nil
36
+ end
37
+
38
+ private
39
+
40
+ def exists?
41
+ File.directory?("LeanIOS/#{language}.lproj")
42
+ end
25
43
  end
26
44
  end
27
45
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module GoNative
4
- VERSION = '1.3.6'
4
+ VERSION = '1.3.8'
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gonative-cli
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.3.6
4
+ version: 1.3.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - Hunaid Hassan
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-11-30 00:00:00.000000000 Z
11
+ date: 2024-02-26 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: dry-cli