Skip to content

Commit

Permalink
Merge pull request #5 from justeattakeaway/yaml-support
Browse files Browse the repository at this point in the history
Add Yaml support
  • Loading branch information
albertodebortoli authored Aug 29, 2024
2 parents b53fcca + 3448c72 commit bbd95d8
Show file tree
Hide file tree
Showing 37 changed files with 726 additions and 531 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -67,15 +67,15 @@
isEnabled = "YES">
</CommandLineArgument>
<CommandLineArgument
argument = "--path Example/Packages/Example"
argument = "--spec Example/Packages/Example.yaml"
isEnabled = "YES">
</CommandLineArgument>
<CommandLineArgument
argument = "--dependencies-path Example/Config/RemoteDependencies.json"
argument = "--dependencies Example/Config/Dependencies.yaml"
isEnabled = "YES">
</CommandLineArgument>
<CommandLineArgument
argument = "--template-path Templates/Package.stencil"
argument = "--template Templates/Package.stencil"
isEnabled = "YES">
</CommandLineArgument>
</CommandLineArguments>
Expand Down
107 changes: 0 additions & 107 deletions .swiftpm/xcode/xcshareddata/xcschemes/GeneratePackages.xcscheme

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,4 @@
"branch": "master"
}
]
}
}
13 changes: 13 additions & 0 deletions Example/Config/Dependencies.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
dependencies:
- name: RemoteDependencyA
url: https://github.com/DependencyA
version: 1.0.0
- name: RemoteDependencyB
url: https://github.com/DependencyB
version: 2.0.0
- name: RemoteDependencyC
url: https://github.com/DependencyC
revision: abcde1235kjh
- name: RemoteDependencyD
url: https://github.com/DependencyC
branch: master
Original file line number Diff line number Diff line change
Expand Up @@ -69,4 +69,4 @@
"path": "../LocalXCFramework.xcframework"
}
]
}
}
38 changes: 38 additions & 0 deletions Example/Packages/Example.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: Example
platforms:
- ".iOS(.v15)"
- ".macOS(.v13)"
swiftToolsVersion: '5.10'
swiftLanguageVersions:
- '5.10'
- '6.0'
products:
- productType: library
name: Example
targets:
- Example
localDependencies:
- name: MyLocalFramework
path: "../MyFrameworks"
remoteDependencies:
- name: RemoteDependencyA
- name: RemoteDependencyB
- name: RemoteDependencyC
targets:
- name: Example
targetType: target
dependencies:
- name: RemoteDependencyA
sourcesPath: Framework/Sources
resourcesPath: Resources
- name: UnitTests
targetType: testTarget
dependencies:
- name: Example
isTarget: true
- name: RemoteDependencyB
sourcesPath: Tests/Sources
resourcesPath: Resources
localBinaryTargets:
- name: LocalXCFramework
path: "../LocalXCFramework.xcframework"
71 changes: 0 additions & 71 deletions Example/Packages/Example/Package.swift

This file was deleted.

9 changes: 9 additions & 0 deletions Package.resolved
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,15 @@
"revision" : "9f39744e025c7d377987f30b03770805dcb0bcd1",
"version" : "1.1.4"
}
},
{
"identity" : "yams",
"kind" : "remoteSourceControl",
"location" : "https://github.com/jpsim/Yams.git",
"state" : {
"revision" : "3036ba9d69cf1fd04d433527bc339dc0dc75433d",
"version" : "5.1.3"
}
}
],
"version" : 2
Expand Down
6 changes: 4 additions & 2 deletions Package.swift
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@ let package = Package(
dependencies: [
.package(url: "https://github.com/apple/swift-argument-parser", from: "1.1.2"),
.package(url: "https://github.com/SwiftGen/StencilSwiftKit", from: "2.8.0"),
.package(url: "https://github.com/JohnSundell/ShellOut", from: "2.3.0")
.package(url: "https://github.com/JohnSundell/ShellOut", from: "2.3.0"),
.package(url: "https://github.com/jpsim/Yams.git", from: "5.0.6")
],
targets: [
.executableTarget(
Expand All @@ -21,14 +22,15 @@ let package = Package(
.product(name: "ArgumentParser", package: "swift-argument-parser"),
.product(name: "ShellOut", package: "ShellOut"),
.product(name: "StencilSwiftKit", package: "StencilSwiftKit"),
.product(name: "Yams", package: "Yams")
],
path: "Sources"),
.testTarget(
name: "PackageGeneratorTests",
dependencies: ["PackageGenerator"],
path: "Tests",
resources: [
.process("Resources")
.copy("Resources")
]
)
]
Expand Down
Loading

0 comments on commit bbd95d8

Please sign in to comment.