UPGRADE YOUR SKILLS: Learn advanced Swift and SwiftUI on Hacking with Swift+! >>

Proper .gitignore use?

Forums > SwiftUI

Hi all,

I have a question about the best gitignore / github setup. I haven't used this file yet for Xcode (I use gitignore at work in Java)

Do we want to push up both the project folder, and the project.xcodeproj folder? Or just one of these?

Example: https://github.com/BillMoriarty/TrackPractice

thanks for any tips -Bill

3      

You want to push both. The project folder contains all the files that make up your project; the .xcodeproj file (which is actually a package, i.e., a folder that macOS treats as a file, which is why it shows up as a folder in github) tells Xcode how to put them all together.

3      

@twostraws  Site AdminHWS+

If you're shipping an app for iOS, macOS, watchOS, or tvOS, you should upload your xcodeproj file and the project directory. If you're building a simple executable using Swift Package Manager, you can skip the xcodeproj and users can make that themselves if they need it. The vast majority of folks are in the first group!

4      

Hacking with Swift is sponsored by RevenueCat

SPONSORED Take the pain out of configuring and testing your paywalls. RevenueCat's Paywalls allow you to remotely configure your entire paywall view without any code changes or app updates.

Learn more here

Sponsor Hacking with Swift and reach the world's largest Swift community!

Archived topic

This topic has been closed due to inactivity, so you can't reply. Please create a new topic if you need to.

All interactions here are governed by our code of conduct.

 
Unknown user

You are not logged in

Log in or create account
 

Link copied to your pasteboard.