I have a Package.swift
// swift-tools-version: 5.9 // The swift-tools-version declares the minimum version of Swift required to build this package. import PackageDescription let package = Package( name: "SharedUI", defaultLocalization: "en_US", platforms: [.iOS(.v16)], products: [ .library( name: "SharedUI", targets: [ "AppTheme", ] ), ], dependencies: [ .package(url: "https://github.com/apple/swift-markdown.git", "0.2.0"..<"0.3.0"), ], targets: [ .target( name: "AppTheme", dependencies: [ .product(name: "Markdown", package: "swift-markdown"), ], path: "AppTheme" ), ] )
Run swift package show-dependencies
shows error
yuantong-macbookpro2:Downloads yuantong$ swift package show-dependencies Fetching https://github.com/apple/swift-markdown.git from cache Fetched https://github.com/apple/swift-markdown.git (0.67s) error: Couldn’t get the list of tags: fatal: cannot use bare repository '/Users/yuantong/Downloads/.build/repositories/swift-markdown-b692ce3c' (safe.bareRepository is 'explicit')
which I think used to work before Xcode 15.
Given that this reproduces when using Swift PM from the command-line [1], you might have more luck asking about it over on the Swift Forums. That’s where the Swift PM experts hang out (-:
Share and Enjoy
—
Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"
[1] While Xcode can use Swift packages, the way that Xcode builds packages is somewhat different than the command-line tool. Thus, if you have a package problem when building from within Xcode, that’s more of an Apple thing. However, if you have a problem when working with the command-line tool, that’s fair game for the Swift Forums.