Skip to content

Commit

Permalink
docs: onlyEnableWithConfig requires configSearchPaths #82
Browse files Browse the repository at this point in the history
  • Loading branch information
vknabel committed Jun 22, 2024
1 parent dc1a963 commit 581be22
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 15 deletions.
22 changes: 9 additions & 13 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,15 +41,15 @@ let package = Package(

## Configuration

| Config | Type | Default | Description |
| --------------------------------------- | ---------- | -------------------------- | --------------------------------------------------------------------------------------------------------------------------------------- |
| `swiftlint.enable` | `Bool` | `true` | Whether SwiftLint should actually do something. |
| `swiftlint.onlyEnableOnSwiftPMProjects` | `Bool` | `false` | Requires and uses a SwiftLint as SwiftPM dependency. |
| `swiftlint.onlyEnableWithConfig` | `Bool` | `false` | Only lint if config present. |
| `swiftlint.path` | `String` | `swiftlint` | The location of the globally installed SwiftLint (resolved with the current path if only a filename). |
| `swiftlint.additionalParameters` | `[String]` | `[]` | Additional parameters to pass to SwiftLint. |
| `swiftlint.configSearchPaths` | `[String]` | `[]` | Possible paths for SwiftLint config. _This disables [nested configurations](https://github.com/realm/SwiftLint#nested-configurations)!_ |
| `swiftlint.autoLintWorkspace` | `Bool` | `true` | Automatically lint the whole project right after start. |
| Config | Type | Default | Description |
| --------------------------------------- | ---------- | ----------- | --------------------------------------------------------------------------------------------------------------------------------------- |
| `swiftlint.enable` | `Bool` | `true` | Whether SwiftLint should actually do something. |
| `swiftlint.onlyEnableOnSwiftPMProjects` | `Bool` | `false` | Requires and uses a SwiftLint as SwiftPM dependency. |
| `swiftlint.onlyEnableWithConfig` | `Bool` | `false` | Only lint if config present. Requires `swiftlint.configSearchPaths`. |
| `swiftlint.path` | `String` | `swiftlint` | The location of the globally installed SwiftLint (resolved with the current path if only a filename). |
| `swiftlint.additionalParameters` | `[String]` | `[]` | Additional parameters to pass to SwiftLint. |
| `swiftlint.configSearchPaths` | `[String]` | `[]` | Possible paths for SwiftLint config. _This disables [nested configurations](https://github.com/realm/SwiftLint#nested-configurations)!_ |
| `swiftlint.autoLintWorkspace` | `Bool` | `true` | Automatically lint the whole project right after start. |

## Commands

Expand All @@ -69,10 +69,6 @@ To automatically fix all issues within a document on save, add the following to
}
```

## Contributors

- Valentin Knabel, [@vknabel](https://github.com/vknabel), [@vknabel](https://twitter.com/vknabel) on Twitter

## License

vscode-swiftlint is available under the [MIT](./LICENSE) license.
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@
"swiftlint.onlyEnableWithConfig": {
"type": "boolean",
"default": false,
"description": "Only use SwiftLint when a config exists."
"description": "Only use SwiftLint when a config exists. Requires `swiftlint.configSearchPaths`."
},
"swiftlint.path": {
"description": "The location of your globally installed SwiftLint.",
Expand Down Expand Up @@ -139,4 +139,4 @@
"glob": "^10.0.0",
"yaml": "^2.3.2"
}
}
}

0 comments on commit 581be22

Please sign in to comment.