Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Lint Markdown files in PRs #5972

Merged
merged 1 commit into from
Jan 19, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 13 additions & 2 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,22 @@ on:
- '*'

jobs:
lint:
name: Lint Repository
lint-swift:
name: Lint Swift
runs-on: ubuntu-24.04 # "Noble Numbat"
container: swift:6.0-noble
steps:
- uses: actions/checkout@v4
- name: Lint
run: swift run swiftlint --reporter github-actions-logging --strict 2> /dev/null
lint-markdown:
name: Lint Markdown
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@v4
- name: Lint
uses: DavidAnson/markdownlint-cli2-action@v19
with:
globs: |
CHANGELOG.md
CONTRIBUTING.md
4 changes: 4 additions & 0 deletions .markdownlint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
MD013:
line_length: 120
MD024:
siblings_only: true
11 changes: 6 additions & 5 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,8 @@
[riley-williams](https://github.com/riley-williams)
[#5958](https://github.com/realm/SwiftLint/issues/5958)

* Add `ib_segue_action` to default configuration of `type_contents_order` rule on the same level as `ib_action` to define and document a standard position.
* Add `ib_segue_action` to default configuration of `type_contents_order` rule on the same level as `ib_action` to
define and document a standard position.
[SimplyDanny](https://github.com/SimplyDanny)
[#5524](https://github.com/realm/SwiftLint/issues/5524)

Expand All @@ -95,14 +96,16 @@
[SimplyDanny](https://github.com/SimplyDanny)

* The artifact bundle name has changed. `SwiftLintBinary-macos.artifactbundle.zip` is now called
`SwiftLintBinary.artifactbundle.zip`. It now includes an AMD64 Linux binary.
`SwiftLintBinary.artifactbundle.zip`. It now includes an AMD64 Linux binary.
[Bradley Mackey](https://github.com/bradleymackey)
[#5514](https://github.com/realm/SwiftLint/issues/5514)

* The `inert_defer` and `unused_capture_list` rules have completely been removed after being deprecated for 2 years.
[SimplyDanny](https://github.com/SimplyDanny)

* SwiftLint now requires a Swift 5.10 or higher compiler to build. [The Swift Package Manager plugins](https://github.com/SimplyDanny/SwiftLintPlugins) continue to work with Swift 5.9.
* SwiftLint now requires a Swift 5.10 or higher compiler to build.
[The Swift Package Manager plugins](https://github.com/SimplyDanny/SwiftLintPlugins) continue to work with
Swift 5.9.
[SimplyDanny](https://github.com/SimplyDanny)

* The `private_unit_test` rule's deprecated `regex` configuration option has been removed after 2 years.
Expand Down Expand Up @@ -8045,5 +8048,3 @@ This release has seen a phenomenal uptake in community contributions!
## 0.1.0: Fresh Out Of The Dryer

First Version!

<!-- markdownlint-configure-file { "MD024": { "siblings_only": true } } -->
4 changes: 3 additions & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,9 @@ Then you can use the full power of Xcode/LLDB/Instruments to develop and debug y
1. `git clone https://github.com/realm/SwiftLint.git`
1. `cd SwiftLint`
1. `swift build [-c release]`
1. Use the produced `swiftlint` binary from the command line, either by running `swift run [-c release] [swiftlint] [arguments]` or by invoking the binary directly at `.build/[release|debug]/swiftlint`
1. Use the produced `swiftlint` binary from the command line, either by running
`swift run [-c release] [swiftlint] [arguments]` or by invoking the binary directly at
`.build/[release|debug]/swiftlint`.
1. For debugging, attach LLDB: `lldb -- .build/[release|debug]/swiftlint [arguments]`

### Code Generation
Expand Down