Commit Graph

289 Commits

Author SHA1 Message Date
Scott Hoyt 8cd2d9f3f2 Removed ruleParametersFromArray from Configuration. 2016-01-11 11:21:49 -08:00
Scott Hoyt 7efb020a4b Added tests for configuring rules from config dictionary. 2016-01-11 11:21:49 -08:00
Scott Hoyt fa7d4024e3 Switched Configurable rule to a failable initializer that takes AnyObject. 2016-01-11 11:21:49 -08:00
Scott Hoyt c2d40c1f94 Extracted all ParameterizedRule conformance to ConfigurableRule out to protocol extension. 2016-01-11 11:21:49 -08:00
Scott Hoyt 3387c0d592 Extracted isEqualTo to protocol extension. 2016-01-11 11:21:49 -08:00
Scott Hoyt 9b6f3070a3 Wrote ConfigurableRule, made ParameterizedRule's conform, moved configuration into rules themselves. 2016-01-11 11:21:49 -08:00
Scott Hoyt eab96555e5 Switch to non optional Configuration initialization from dictionary. 2016-01-11 11:18:54 -08:00
Scott Hoyt 6510960fa6 Began extracting Yaml dependency out of Configuration and into YamlParser 2016-01-11 11:18:54 -08:00
Scott Hoyt e797f9d282 Remove unnecessary Yaml extensions. 2016-01-11 11:18:54 -08:00
Scott Hoyt 31b9cc0149 Remove redundant YAML functions from Configuration. 2016-01-11 11:18:54 -08:00
Scott Hoyt f0cb4d81c3 Added dictionary-based initialization for Configuration. 2016-01-11 11:14:54 -08:00
Scott Hoyt 909ca9fcb6 Added masterRuleList. 2016-01-11 11:14:54 -08:00
Scott Hoyt ddcc67273b Added tests for new Yaml+SwiftLint extensions. 2016-01-11 11:14:54 -08:00
Scott Hoyt 2731c8ee55 Added flattening extensions to Yaml. 2016-01-11 11:14:54 -08:00
Scott Hoyt a81b228e5f Extracted Yaml extensions out of Configuration.swift 2016-01-11 11:14:54 -08:00
JP Simard a0a76d898f fix escaped double quote character 2016-01-11 08:55:10 -08:00
JP Simard 8fbc88254c escape strings when using CSV reporter 2016-01-11 08:50:15 -08:00
Aaron McTavish 7b046465c8 Fixed two more edge cases for non-triggering examples 2016-01-11 07:41:56 -08:00
Aaron McTavish c5873a4620 Fixed alphabetising list 2016-01-11 07:40:44 -08:00
Aaron McTavish fb234901df Fix initial newline 2016-01-11 07:40:41 -08:00
Aaron McTavish 1b6dbabb40 Improve performance of ConditionalBindingCascadeRule 2016-01-11 07:40:33 -08:00
Aaron McTavish fe3136d8ff Adding ConditionalBindingCascadeRule 2016-01-11 07:40:16 -08:00
Norio Nomura 7fa100a033 Reduce calls to String.characters.count in LineLengthRule.validateFile(_:)
By applying this, the duration of linting Carthage is reduced from:
```
swiftlint lint  20.07s user 1.10s system 84% cpu 25.023 total
```
to:
```
swiftlint lint  18.27s user 1.05s system 84% cpu 22.769 total
```
2016-01-10 20:44:36 +09:00
JP Simard f3cf551c12 Merge pull request #333 from realm/nn-reducing-calls-to-sourcekit
Add SourceKit response cache for reducing calls to SourceKit
2016-01-09 10:22:01 -08:00
Norio Nomura 755619d3f8 Add SourceKit response cache for reducing calls to SourceKit
This depends on https://github.com/jpsim/SourceKitten/pull/135
By applying this, the duration of linting Carthage is reduced from:
```
swiftlint lint  27.85s user 1.98s system 77% cpu 38.538 total
```
to:
```
swiftlint lint  21.15s user 1.26s system 80% cpu 27.743 total
```
2016-01-09 23:49:07 +09:00
Eric Bailey b33c5d870f Update CommaRule.swift
Reword the description a bit, based on @jpsim's suggestion.
2016-01-09 01:42:47 -06:00
Eric Bailey a7b65b2570 Fix typo in CommaRule.swift
The description implied the opposite of the rule.
2016-01-09 00:02:25 -06:00
Raphael Randschau d9a885e5b5 Add AutoCorrect for LegacyConstructorRule 2016-01-08 23:02:09 +01:00
Raphael Randschau e4f27dab63 Add autocorrect for CommaRule 2016-01-08 21:49:32 +01:00
JP Simard ef4e3c9ddf Merge pull request #325 from realm/nn-fix-324
Fix regex for ignoring closure parameter on detecting return value
2016-01-07 16:28:58 -08:00
Norio Nomura 8edc234e64 Fix regex for ignoring closure parameter on detecting return value
fix #324
2016-01-08 09:12:17 +09:00
Norio Nomura e1b8a12376 Add failing example 2016-01-08 08:57:49 +09:00
Raphael Randschau 02834c89c0 StatementPositionRule is a correctable rule 2016-01-07 20:02:51 +01:00
Jonas Schmid cecaddf95c Missing space in doc 2016-01-06 10:54:32 +01:00
John Estropia 897f2781a3 fixed trailing whitespace linter error 2016-01-05 15:58:29 +09:00
John Estropia dee61e7eb3 optimize counting newlines 2016-01-05 15:53:59 +09:00
John Estropia ccad677169 fix trailingNewlineCount() returning wrong count 2016-01-05 14:51:23 +09:00
JP Simard 3b9aa3bb4d release 0.5.5 2016-01-04 13:50:49 -08:00
JP Simard 8cc8c63414 Merge pull request #317 from realm/jp-fix-316
make commands with modifiers work for violations with line-only locations
2016-01-04 13:34:09 -08:00
JP Simard d60a85aae0 make commands with modifiers work for violations with line-only locations 2016-01-04 13:25:57 -08:00
Sebastian Grail 2d27db5e1f Fix typo in FunctionBodyLengthRule and TypeBodyLengthRule 2016-01-04 15:38:54 +11:00
JP Simard 948566ae2f fail if YAML doesn't parse 2016-01-03 14:11:27 -08:00
JP Simard 4421657de5 release 0.5.4 2016-01-02 16:13:43 -08:00
JP Simard fc3545be1b minor refactorings 2016-01-02 15:59:16 -08:00
JP Simard 281a4dc587 no longer mirror some NSString methods in a String extension 2016-01-02 15:52:56 -08:00
Scott Hoyt 5b023501c2 Tested merge. 2016-01-02 15:41:53 -08:00
Scott Hoyt 7b2f4bff43 Moved == implementation for [Rule] to more appropriate spot. Wrote missing test. 2016-01-02 15:41:53 -08:00
Scott Hoyt fcf9396a08 Added isEqual for Rule and ParameterizedRule. Made Configuration and RuleParameter conform to Equatable. Wrote tests to verify. All done in support of testing recursive configuration file search. 2016-01-02 15:41:53 -08:00
Scott Hoyt 88749c1e87 Updated comments. 2016-01-02 15:41:53 -08:00
Scott Hoyt 4361adca10 Silence the logging inside of Configuration.init instead. 2016-01-02 15:41:53 -08:00