diff --git a/.github/workflows/swiftlint.yml b/.github/workflows/swiftlint.yml new file mode 100644 index 00000000..4ac3e82b --- /dev/null +++ b/.github/workflows/swiftlint.yml @@ -0,0 +1,18 @@ +name: SwiftLint + +on: + pull_request: + paths: + - '.github/workflows/swiftlint.yml' + - '.swiftlint.yml' + - '**/*.swift' + +jobs: + SwiftLint: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v1 + - name: Run SwiftLint + uses: norio-nomura/action-swiftlint@3.2.1 + with: + args: --strict diff --git a/.swiftlint.yml b/.swiftlint.yml index fe357b2e..e84370cf 100644 --- a/.swiftlint.yml +++ b/.swiftlint.yml @@ -409,7 +409,6 @@ function_body_length: included: - Sources - - Examples excluded: - .swiftpm diff --git a/ComponentsKit.xcworkspace/xcshareddata/swiftpm/Package.resolved b/ComponentsKit.xcworkspace/xcshareddata/swiftpm/Package.resolved index 33f42961..0770c436 100644 --- a/ComponentsKit.xcworkspace/xcshareddata/swiftpm/Package.resolved +++ b/ComponentsKit.xcworkspace/xcshareddata/swiftpm/Package.resolved @@ -8,15 +8,6 @@ "revision" : "78e39facca2cc459a135655cae0e9feb5a587892", "version" : "1.0.0" } - }, - { - "identity" : "swiftlintplugins", - "kind" : "remoteSourceControl", - "location" : "https://github.com/SimplyDanny/SwiftLintPlugins", - "state" : { - "revision" : "7c80ce6f142164b0201871e580b021d1b2c69804", - "version" : "0.57.0" - } } ], "version" : 2 diff --git a/Package.swift b/Package.swift index 12b83793..3bed349e 100644 --- a/Package.swift +++ b/Package.swift @@ -15,16 +15,12 @@ let package = Package( ], dependencies: [ .package(url: "https://github.com/componentskit/AutoLayout", from: "1.0.0"), - .package(url: "https://github.com/SimplyDanny/SwiftLintPlugins", from: "0.57.0"), ], targets: [ .target( name: "ComponentsKit", dependencies: [ .product(name: "AutoLayout", package: "AutoLayout") - ], - plugins: [ - .plugin(name: "SwiftLintBuildToolPlugin", package: "SwiftLintPlugins") ] ) ]