When I create Xcode workspace project and added Swift Package and wrapper project to test Swift Package it all works fine. But when I try to pull this repo from other projects using git url it complains about Package.swift(manifest) file is not present in the Root folder. Is there any solution for this. Do I have to manually drag the Package.swift file to root folder and change the path settings in it?
Asked
Active
Viewed 119 times
0
-
Your `Package.swift` manifest file must be at the root of the repo to work with SwiftPM. If you want an Xcode project/workspace with it then you need to put it down into another directory of the repo and reach back up to the `Package.swift` via a relative path. – bscothern Jun 18 '21 at 17:29
1 Answers
1
when I had empty git repo created, instead of creating new Swift package inside the repo which created extra project folder with Package.swfit inside it, I just ran "swift package init --type library" inside the repo so that package.swift is created in the Root folder and takes the repo name as the package name. we can also change the package name if we want to.
Git Repo iOS-NewRepo -> Package.swift Sources Tets

SreekanthI
- 393
- 3
- 13