A Swift library that simplifies the creation, configuration, and management of Xcode projects
Add the following dependency to your Package.swift
file:
dependencies: [
.package(url: "https://github.com/YassineLafryhi/EasyXCProj.git", from: "0.9.0")
]
import Foundation
import EasyXCProj
let excp = EasyXCProj()
let projectPath = NSHomeDirectory() + "/Desktop/MyTestProject"
excp.createNewProject(
projectName: "MyTestProject",
projectPath: projectPath,
projectType: .iOSApp,
bundleIdentifier: "com.company.name.MyTestProject",
deploymentTarget: "15.0",
displayName: "My Test Project",
sources: "Sources",
resources: "Resources")
import Foundation
import EasyXCProj
let excp = EasyXCProj()
let projectPath = NSHomeDirectory() + "/Desktop/MyTestProject"
excp.loadProject(from: projectPath)
excp.addSPMLibrary(
targetName: "MyTestProject",
productName: "Alamofire",
gitUrl: "https://github.com/Alamofire/Alamofire.git",
version: "5.9.1")
import Foundation
import EasyXCProj
let excp = EasyXCProj()
let projectPath = NSHomeDirectory() + "/Desktop/MyTestProject"
excp.loadProject(from: projectPath)
try? excp.addBuildScriptBeforeCompileSources(targetName: "MyTestProject", name: "Lint Code With SwiftLint", script: """
if command -v swiftlint >/dev/null 2>&1
then
swiftlint
else
echo "warning: `swiftlint` command not found - See https://github.com/realm/SwiftLint#installation for installation instructions."
fi
""")
Contributions are what make the open source community such an amazing place to learn, inspire, and create. Any contributions you make are greatly appreciated.
- Fork the Project
- Create your Feature Branch (
git checkout -b feature/AmazingFeature
) - Commit your Changes (
git commit -m 'Add some AmazingFeature'
) - Push to the Branch (
git push origin feature/AmazingFeature
) - Open a Pull Request