File tree Expand file tree Collapse file tree 1 file changed +13
-0
lines changed
Sources/BuildSystemIntegration Expand file tree Collapse file tree 1 file changed +13
-0
lines changed Original file line number Diff line number Diff line change @@ -578,6 +578,13 @@ package actor SwiftPMBuildSystem: BuiltInBuildSystem {
578578 data: SourceKitSourceItemData ( isHeader: true ) . encodeToLSPAny ( )
579579 )
580580 }
581+ sources += ( swiftPMTarget. resources + swiftPMTarget. ignored + swiftPMTarget. others) . map {
582+ SourceItem (
583+ uri: DocumentURI ( $0) ,
584+ kind: $0. isDirectory ? . directory : . file,
585+ generated: false ,
586+ )
587+ }
581588 result. append ( SourcesItem ( target: target, sources: sources) )
582589 }
583590 return BuildTargetSourcesResponse ( items: result)
@@ -773,3 +780,9 @@ package actor SwiftPMBuildSystem: BuiltInBuildSystem {
773780 return TextDocumentSourceKitOptionsResponse ( compilerArguments: compilerArgs)
774781 }
775782}
783+
784+ fileprivate extension URL {
785+ var isDirectory : Bool {
786+ ( try ? resourceValues ( forKeys: [ . isDirectoryKey] ) ) ? . isDirectory == true
787+ }
788+ }
You can’t perform that action at this time.
0 commit comments