Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed source_files ending with / to stop generationg srcs like 'some//**/*' #213

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
59 changes: 59 additions & 0 deletions Examples/PodSpecs/PhoneNumberKit.podspec.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
{
"name": "PhoneNumberKit",
"version": "3.3.4",
"summary": "Swift framework for working with phone numbers",
"description": "A Swift framework for parsing, formatting and validating international phone numbers. Inspired by Google's libphonenumber.",
"homepage": "https://github.com/marmelroy/PhoneNumberKit",
"license": "MIT",
"authors": {
"Roy Marmelstein": "[email protected]"
},
"source": {
"git": "https://github.com/marmelroy/PhoneNumberKit.git",
"tag": "3.3.4"
},
"social_media_url": "http://twitter.com/marmelroy",
"requires_arc": true,
"ios": {
"frameworks": "CoreTelephony"
},
"osx": {
"frameworks": "CoreTelephony"
},
"platforms": {
"ios": "9.0",
"osx": "10.10",
"tvos": "10.0",
"watchos": "2.0"
},
"pod_target_xcconfig": {
"SWIFT_VERSION": "5.0"
},
"swift_versions": "5.0",
"subspecs": [
{
"name": "PhoneNumberKitCore",
"platforms": {
"ios": "9.0",
"osx": "10.10",
"tvos": "10.0",
"watchos": "2.0"
},
"source_files": "PhoneNumberKit/*.{swift}",
"resources": "PhoneNumberKit/Resources/PhoneNumberMetadata.json"
},
{
"name": "UIKit",
"dependencies": {
"PhoneNumberKit/PhoneNumberKitCore": [

]
},
"platforms": {
"ios": "9.0"
},
"source_files": "PhoneNumberKit/UI/"
}
],
"swift_version": "5.0"
}
4 changes: 3 additions & 1 deletion Sources/PodToBUILD/PodSpec.swift
Original file line number Diff line number Diff line change
Expand Up @@ -223,7 +223,9 @@ public struct PodSpec: PodSpecRepresentable {
frameworks = strings(fromJSON: fieldMap[.frameworks])
weakFrameworks = strings(fromJSON: fieldMap[.weakFrameworks])
excludeFiles = strings(fromJSON: fieldMap[.excludeFiles])
sourceFiles = strings(fromJSON: fieldMap[.sourceFiles])
sourceFiles = strings(fromJSON: fieldMap[.sourceFiles]).map({
$0.hasSuffix("/") ? String($0.dropLast()) : $0
})
publicHeaders = strings(fromJSON: fieldMap[.publicHeaders])
privateHeaders = strings(fromJSON: fieldMap[.privateHeaders])

Expand Down