xcodeproj 1.9.0 → 1.10.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: d75afee284a642e23fb795b6b34a6c4e486126a2843aefc1bec368f64a3a913d
4
- data.tar.gz: be3b241febabcee98279667700d8e852394bd85ae611ae64de5fa197b2e2d6c2
3
+ metadata.gz: 3c97e1a1e73c9358014593b72f840b6f82f0560c525aee2a98f11a482bac7887
4
+ data.tar.gz: 35f3b030a485fadcb4d65a5f949805d29ef94f66815b72578485a74993a01135
5
5
  SHA512:
6
- metadata.gz: f71583b1d4b0478bfb4fc99f9a6e17e6016b17e8c7454c2d5b794709f534eda1eee860e3cbf8cbe979291b497f9540e3049c5c58fc0bd71364511f52f110559c
7
- data.tar.gz: 90900a1315731d9b92affef9d749a135c75834e8a3d01d1efca3c955899cc6ad0e550843dafbe2043e0789dd5bf72ecb0e526972dc0337dac7896c14230518d6
6
+ metadata.gz: d782cfd8c7f9b80303a100d277969c69738a037d8d86388292c5fd84a443686100f7a18681d68752fa1abae946714ef4dd413e957de14ae6488f2fa0c6bd3de6
7
+ data.tar.gz: 12ec3dbcee3d913fc1b92bef15a6f65a1ff90866bd92295eb674574de9db3b234e79cba17fc8d8f6c4d4ddb1188d46894f0483be25e25fa217c6cbc750890b5d
@@ -32,15 +32,15 @@ module Xcodeproj
32
32
 
33
33
  # @return [String] The last known object version to Xcodeproj.
34
34
  #
35
- LAST_KNOWN_OBJECT_VERSION = 51
35
+ LAST_KNOWN_OBJECT_VERSION = 52
36
36
 
37
37
  # @return [String] The last known object version to Xcodeproj.
38
38
  #
39
- LAST_UPGRADE_CHECK = '1020'
39
+ LAST_UPGRADE_CHECK = '1100'
40
40
 
41
41
  # @return [String] The last known object version to Xcodeproj.
42
42
  #
43
- LAST_SWIFT_UPGRADE_CHECK = '1020'
43
+ LAST_SWIFT_UPGRADE_CHECK = '1100'
44
44
 
45
45
  # @return [String] The version of `.xcscheme` files supported by Xcodeproj
46
46
  #
@@ -126,6 +126,7 @@ module Xcodeproj
126
126
  # @return [Hash] The compatibility version string for different object versions.
127
127
  #
128
128
  COMPATIBILITY_VERSION_BY_OBJECT_VERSION = {
129
+ 52 => 'Xcode 11.0',
129
130
  51 => 'Xcode 10.0',
130
131
  50 => 'Xcode 9.3',
131
132
  48 => 'Xcode 8.0',
@@ -1,5 +1,5 @@
1
1
  module Xcodeproj
2
2
  # The version of the xcodeproj gem.
3
3
  #
4
- VERSION = '1.9.0'.freeze unless defined? Xcodeproj::VERSION
4
+ VERSION = '1.10.0'.freeze unless defined? Xcodeproj::VERSION
5
5
  end
@@ -518,6 +518,8 @@ Xcodeproj::Constants::KNOWN_ISAS.each do |superclass_name, isas|
518
518
  end
519
519
 
520
520
  # Now load the concrete subclasses.
521
+ require 'xcodeproj/project/object/swift_package_remote_reference'
522
+ require 'xcodeproj/project/object/swift_package_product_dependency'
521
523
  require 'xcodeproj/project/object/build_configuration'
522
524
  require 'xcodeproj/project/object/build_file'
523
525
  require 'xcodeproj/project/object/build_phase'
@@ -18,7 +18,7 @@ module Xcodeproj
18
18
  #
19
19
  attribute :settings, Hash
20
20
 
21
- # @return [PBXFileReference] the file that to build.
21
+ # @return [PBXFileReference] the file to build.
22
22
  #
23
23
  # @todo I think that is possible to add any kind of group (for
24
24
  # example folders linked to a path).
@@ -31,6 +31,14 @@ module Xcodeproj
31
31
  PBXReferenceProxy,
32
32
  ]
33
33
 
34
+ # @return [XCSwiftPackageProductDependency] the Swift Package file to build.
35
+ #
36
+ has_one :product_ref, XCSwiftPackageProductDependency
37
+
38
+ # @return [String] the platform filter for this build file.
39
+ #
40
+ attribute :platform_filter, String
41
+
34
42
  #---------------------------------------------------------------------#
35
43
 
36
44
  public
@@ -41,6 +41,11 @@ module Xcodeproj
41
41
  #
42
42
  attribute :is_editable, String, '1'
43
43
 
44
+ # @return [ObjectList<PBXFileReference>] the file references for the
45
+ # input files files.
46
+ #
47
+ attribute :input_files, Array
48
+
44
49
  # @return [ObjectList<PBXFileReference>] the file references for the
45
50
  # output files.
46
51
  #
@@ -309,7 +309,7 @@ module Xcodeproj
309
309
  # Adds a file reference for one or more system framework to the project
310
310
  # if needed and adds them to the Frameworks build phases.
311
311
  #
312
- # @param [Array<String>, String] name
312
+ # @param [Array<String>, String] names
313
313
  # The name or the list of the names of the framework.
314
314
  #
315
315
  # @note Xcode behaviour is following: if the target has the same SDK
@@ -359,7 +359,7 @@ module Xcodeproj
359
359
  # Adds a file reference for one or more system dylib libraries to the project
360
360
  # if needed and adds them to the Frameworks build phases.
361
361
  #
362
- # @param [Array<String>, String] name
362
+ # @param [Array<String>, String] names
363
363
  # The name or the list of the names of the libraries.
364
364
  #
365
365
  # @return [void]
@@ -385,7 +385,7 @@ module Xcodeproj
385
385
  # Adds a file reference for one or more system tbd libraries to the project
386
386
  # if needed and adds them to the Frameworks build phases.
387
387
  #
388
- # @param [Array<String>, String] name
388
+ # @param [Array<String>, String] names
389
389
  # The name or the list of the names of the libraries.
390
390
  #
391
391
  # @return [void]
@@ -432,6 +432,11 @@ module Xcodeproj
432
432
  #
433
433
  has_one :product_reference, PBXFileReference
434
434
 
435
+ # @return [ObjectList<XCSwiftPackageProductDependency>] the Swift package products necessary to
436
+ # build this target.
437
+ #
438
+ has_many :package_product_dependencies, XCSwiftPackageProductDependency
439
+
435
440
  # @return [String] the install path of the product.
436
441
  #
437
442
  attribute :product_install_path, String
@@ -622,6 +627,22 @@ module Xcodeproj
622
627
  end
623
628
  end
624
629
  end
630
+
631
+ def to_hash_as(method = :to_hash)
632
+ hash_as = super
633
+ if !hash_as['packageProductDependencies'].nil? && hash_as['packageProductDependencies'].empty?
634
+ hash_as.delete('packageProductDependencies')
635
+ end
636
+ hash_as
637
+ end
638
+
639
+ def to_ascii_plist
640
+ plist = super
641
+ if !plist.value['packageProductDependencies'].nil? && plist.value['packageProductDependencies'].empty?
642
+ plist.value.delete('packageProductDependencies')
643
+ end
644
+ plist
645
+ end
625
646
  end
626
647
 
627
648
  #-----------------------------------------------------------------------#
@@ -62,6 +62,10 @@ module Xcodeproj
62
62
  #
63
63
  attribute :project_root, String, ''
64
64
 
65
+ # @return [Array<XCRemoteSwiftPackageReference>] the list of Swift package references.
66
+ #
67
+ has_many :package_references, XCRemoteSwiftPackageReference
68
+
65
69
  # @return [Array<ObjectDictionary>] any reference to other projects.
66
70
  #
67
71
  has_many_references_by_keys :project_references,
@@ -76,9 +80,18 @@ module Xcodeproj
76
80
  ' Project object '
77
81
  end
78
82
 
83
+ def to_hash_as(method = :to_hash)
84
+ hash_as = super
85
+ if !hash_as['packageReferences'].nil? && hash_as['packageReferences'].empty?
86
+ hash_as.delete('packageReferences') if !hash_as['packageReferences'].nil? && hash_as['packageReferences'].empty?
87
+ end
88
+ hash_as
89
+ end
90
+
79
91
  def to_ascii_plist
80
92
  plist = super
81
93
  plist.value.delete('projectReferences') if plist.value['projectReferences'].empty?
94
+ plist.value.delete('packageReferences') if !plist.value['packageReferences'].nil? && plist.value['packageReferences'].empty?
82
95
  plist
83
96
  end
84
97
  end
@@ -0,0 +1,19 @@
1
+ module Xcodeproj
2
+ class Project
3
+ module Object
4
+ # This class represents a Swift package product dependency.
5
+ #
6
+ class XCSwiftPackageProductDependency < AbstractObject
7
+ # @!group Attributes
8
+
9
+ # @return [XCRemoteSwiftPackageReference] the Swift package reference.
10
+ #
11
+ has_one :package, XCRemoteSwiftPackageReference
12
+
13
+ # @return [String] the product name of this Swift package.
14
+ #
15
+ attribute :product_name, String
16
+ end
17
+ end
18
+ end
19
+ end
@@ -0,0 +1,19 @@
1
+ module Xcodeproj
2
+ class Project
3
+ module Object
4
+ # This class represents a Swift package reference.
5
+ #
6
+ class XCRemoteSwiftPackageReference < AbstractObject
7
+ # @!group Attributes
8
+
9
+ # @return [String] the repository url this Swift package was installed from.
10
+ #
11
+ attribute :repositoryURL, String
12
+
13
+ # @return [Hash] the version requirements for this Swift package.
14
+ #
15
+ attribute :requirement, Hash
16
+ end
17
+ end
18
+ end
19
+ end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: xcodeproj
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.9.0
4
+ version: 1.10.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Eloy Duran
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-05-02 00:00:00.000000000 Z
11
+ date: 2019-06-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: atomos
@@ -135,6 +135,8 @@ files:
135
135
  - lib/xcodeproj/project/object/native_target.rb
136
136
  - lib/xcodeproj/project/object/reference_proxy.rb
137
137
  - lib/xcodeproj/project/object/root_object.rb
138
+ - lib/xcodeproj/project/object/swift_package_product_dependency.rb
139
+ - lib/xcodeproj/project/object/swift_package_remote_reference.rb
138
140
  - lib/xcodeproj/project/object/target_dependency.rb
139
141
  - lib/xcodeproj/project/object_attributes.rb
140
142
  - lib/xcodeproj/project/object_dictionary.rb