Closed briancordanyoung closed 2 years ago
Hey! Danger is now at version 3.12.3 https://github.com/danger/swift/releases/tag/3.12.3 I think a Package.swift like this should work
// swift-tools-version:5.5
import PackageDescription
let package = Package(
name: "DangerSetup",
products: [
.library(name: "DangerDeps", type: .dynamic, targets: ["DangerSetup"]) // Danger needs to build and link this in order to work correcly
],
dependencies: [
.package(url: "https://github.com/danger/swift.git", from: "3.0.0")
],
targets: [
// This is just an arbitrary Swift file in our app, that has
// no dependencies outside of Foundation, the dependencies section
// ensures that the library for Danger gets build also.
.target(
name: "DangerSetup",
dependencies: [.product(name: "Danger", package: "swift")],
path: "dummy",
sources: ["dummy.swift"]
),
]
)
Ahhhh. 🤦♂️ Thank you!
I am new to danger. This is the first time I've tried to set up danger-swift. When I try to run locally on a PR it fails with the error below. I get the same error when running the homebrew installed
danger-swift
command or through swift build.danger-swift pr https://github.com/danger/swift/pull/440
swift run danger-swift pr https://github.com/danger/swift/pull/440
Does this look familiar to anyone?
My enviornment:
Error
Package.swift: