Created
September 17, 2024 14:16
-
-
Save AFutureD/fbde217b9b1e9b3ab7312bc62dc6e5fc to your computer and use it in GitHub Desktop.
Swift LSP support for iOS on vscode
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// .sourcekit-lsp/config.json | |
{ | |
"swiftPM": { | |
"triple": "arm64-apple-ios-simulator", | |
"swiftCompilerFlags": [ | |
"-sdk", | |
"/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk", | |
"-target", | |
"arm64-apple-ios18.0-simulator" | |
], | |
"cCompilerFlags": [ | |
"-isysroot", | |
"/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk" | |
] | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// .vscode/extensions.json | |
{ | |
"recommendations": [ | |
"sswg.swift-lang" | |
] | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// .vscode/settings.json | |
{ | |
"swift.SDK": "/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk", | |
"swift.buildArguments": [ | |
"--triple", | |
"arm64-apple-ios-simulator", | |
"-Xswiftc", | |
"-target", | |
"-Xswiftc", | |
"arm64-apple-ios18.0-simulator" | |
], | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"folders": [ | |
{ | |
"path": "." | |
}, | |
{ | |
"name": "Swift Package Dependencies", | |
"path": ".build/checkouts" | |
} | |
], | |
"extensions": { | |
"recommendations": ["sswg.swift-lang"], | |
}, | |
"settings": { | |
"files.exclude": { | |
".build": true, | |
".swiftpm": true | |
}, | |
"swift.SDK": "/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk", | |
"swift.buildArguments": [ | |
"--triple", | |
"arm64-apple-ios-simulator", | |
"-Xswiftc", | |
"-target", | |
"-Xswiftc", | |
"arm64-apple-ios18.0-simulator" | |
], | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The configuration does not support *.xcworkspace or *.xcodeproj for now, but it does support Swift Packages.