Skip to content

Commit

Permalink
Add build-script.sh file to run linters locally + fix SwiftLint warns
Browse files Browse the repository at this point in the history
  • Loading branch information
Jeehut committed Apr 9, 2023
1 parent 143f9b6 commit 0496714
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 6 deletions.
10 changes: 5 additions & 5 deletions CHANGELOG.md
Expand Up @@ -33,13 +33,13 @@ If needed, pluralize to `Tasks`, `PRs` or `Authors` and list multiple entries se

## [0.11.0] - 2023-04-09
### Added
- Added a new `--unvalidated` (`-u`) option for running all checks without running the validations provided, such as testing for `matchingExamples` and `nonMatchingExamples`. Use with cuation.
- Added a new `--unvalidated` (`-u`) option for running all checks without running the validations provided, such as testing for `matchingExamples` and `nonMatchingExamples`. Use with cuation.
### Changed
- Some internal code clean-up.
- Upgrade to Swift 5.7 manifest syntax.
- Some internal code clean-up.
- Upgrade to Swift 5.7 manifest syntax.
### Fixed
- The `--measure` option also measured validations & files search which distorted the measure time for the first check with the same files search. Now, it only measures the actual matching time of the Regex for better evaluation.

- The `--measure` option also measured validations & files search which distorted the measure time for the first check with the same files search. Now, it only measures the actual matching time of the Regex for better evaluation.
## [0.10.1] - 2022-05-27
### Changed
- Improved output color & formatting of new `--measure` option for printing execution time per check.
Expand Down
6 changes: 5 additions & 1 deletion Sources/AnyLintCLI/Commands/SingleCommand.swift
Expand Up @@ -23,7 +23,11 @@ class SingleCommand: Command {
@Flag("-l", "--validate", description: "Runs only validations for `matchingExamples`, `nonMatchingExamples` and `autoCorrectExamples`.")
var validate: Bool

@Flag("-u", "--unvalidated", description: "Runs the checks without validating their correctness. Only use for faster subsequent runs after a validated run succeeded.")
@Flag(
"-u",
"--unvalidated",
description: "Runs the checks without validating their correctness. Only use for faster subsequent runs after a validated run succeeded."
)
var unvalidated: Bool

@Flag("-m", "--measure", description: "Prints the time it took to execute each check for performance optimizations")
Expand Down
5 changes: 5 additions & 0 deletions build-script.sh
@@ -0,0 +1,5 @@
#!/bin/bash
set -euxo pipefail

anylint --strict
swiftlint --strict

0 comments on commit 0496714

Please sign in to comment.