Method: Pod::Podfile::DSL#supports_swift_versions

Defined in:
lib/cocoapods-core/podfile/dsl.rb

#supports_swift_versions(*requirements) ⇒ void

This method returns an undefined value.

Specifies the Swift version requirements this target definition supports.

Note These requirements are inherited from the parent, if specified and if none are specified at the root level then all versions are considered to be supported.

Examples:


target 'MyApp' do
  supports_swift_versions '>= 3.0', '< 4.0'
  pod 'AFNetworking', '~> 1.0'
end

supports_swift_versions '>= 3.0', '< 4.0'

target 'MyApp' do
  pod 'AFNetworking', '~> 1.0'
end

target 'ZipApp' do
  pod 'SSZipArchive'
end

Parameters:

  • requirements (String, Version, Array<String>, Array<Version>)

    The set of requirements this target supports.



781
782
783
# File 'lib/cocoapods-core/podfile/dsl.rb', line 781

def supports_swift_versions(*requirements)
  current_target_definition.store_swift_version_requirements(*requirements)
end