Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Proximie/action-swiftlint

 
 

Repository files navigation

GitHub Action for SwiftLint

This Action executes SwiftLint and generates annotations from SwiftLint Violations.

Usage

An example workflow(.github/workflows/swiftlint.yml) to executing SwiftLint follows:

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: GitHub Action for SwiftLint
        uses: proximie/[email protected]
      - name: GitHub Action for SwiftLint with --strict
        uses: proximie/[email protected]
        with:
          args: --strict
      - name: GitHub Action for SwiftLint (Only files changed in the PR)
        uses: proximie/[email protected]
        env:
          DIFF_BASE: ${{ github.base_ref }}
      - name: GitHub Action for SwiftLint (Different working directory)
        uses: proximie/[email protected]
        env:
          WORKING_DIRECTORY: Source

Versions

The action version reflects the swiftlint version, the minimum provided version is v0.54.0.

Example

Here is an example that actually works. screenshot

Author

Proximie

License

MIT

About

GitHub Action for SwiftLint

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Swift 73.7%
  • Shell 24.4%
  • Dockerfile 1.9%