Commit graph

352 commits

Author SHA1 Message Date
Sijawusz Pur Rahnama
d2fa75280f
Extend JoinAfterMap to check also calls to sum/product and rename it to MapInsteadOfBlock (#190) 2021-01-18 17:42:50 +02:00
Vitalii Elenhaupt
e9ec91654c New Rule: Lint/DuplicatedRequire
closes https://github.com/crystal-ameba/ameba/issues/176
2021-01-17 22:32:24 +02:00
Sijawusz Pur Rahnama
6898aa8976
Fix issue #187 (#189)
* Avoid using `tap` with structs

* Remove extraneous blank lines

* Readability
2021-01-17 22:31:53 +02:00
Sijawusz Pur Rahnama
928a260d51 Remove extraneous blank lines 2021-01-17 18:45:14 +01:00
Sijawusz Pur Rahnama
af5d825015 Followup to #185 2021-01-17 18:45:14 +01:00
Sijawusz Pur Rahnama
fd4b2f309c Don’t allocate the array on every call 2021-01-17 18:05:08 +01:00
Sijawusz Pur Rahnama
5e58a60ade Move constant definitions after properties call 2021-01-17 17:39:32 +01:00
Sijawusz Pur Rahnama
66a4b283d4
Merge pull request #186 from crystal-ameba/feature/join-after-map
Add Performance/JoinAfterMap rule
2021-01-17 16:59:51 +01:00
Sijawusz Pur Rahnama
a892cd43b0 Add Performance/JoinAfterMap rule 2021-01-17 16:57:15 +01:00
Sijawusz Pur Rahnama
06852c490b Followup to #185 2021-01-17 13:25:50 +01:00
Sijawusz Pur Rahnama
1a091c1f1a
Optimize rules (#185)
* Replace pointless interpolations with actual values

* Rules optimizations

* Stylistic refactors

* Remove extraneous blank lines

* Remove some instances of .not_nil! usage
2021-01-17 14:16:04 +02:00
Sijawusz Pur Rahnama
270a003df6
Merge pull request #184 from mamantoha/fix-crystal-nightly
fix Crystal nightly
2021-01-16 19:53:48 +01:00
Anton Maminov
6f0f8352f9 fix Crystal nightly 2021-01-16 20:42:27 +02:00
Sijawusz Pur Rahnama
c4d34d74d8
Add support for showing code context lines (#181)
* Add support for showing code context lines

* Show context lines only in ExplainFormatter

* Add spec coverage for context_lines option
2021-01-12 17:20:43 +02:00
Vitalii Elenhaupt
9bc6c13d11
Merge branch 'master' into develop 2021-01-12 12:03:23 +02:00
Vitalii Elenhaupt
bedf3a68d7
Merge pull request #182 from crystal-ameba/Sija/move-ci-to-github-actions
Switch CI from Travis to GitHub Actions
2021-01-12 12:03:00 +02:00
Sijawusz Pur Rahnama
d20952127a Add deploy docs workflow 2021-01-12 02:56:47 +01:00
Sijawusz Pur Rahnama
69f3921a68 Switch CI from Travis to GitHub Actions 2021-01-12 02:56:47 +01:00
Sijawusz Pur Rahnama
19c370aee0
Misc refactors (#180)
* Optimize Severity#symbol

* Remove empty else branches

* Optimize map+compact/flatten calls

* Misc stylistic refactors
2021-01-11 20:13:58 +02:00
Vitalii Elenhaupt
9d85e731f5
Merge pull request #179 from crystal-ameba/feature/cli-show-all-rules
Add --rules switch to the CLI
2021-01-10 09:34:40 +02:00
Sijawusz Pur Rahnama
2eff832669 Add --rules switch to the CLI 2021-01-09 21:01:04 +01:00
Vitalii Elenhaupt
552d31a82b
Bump v0.13.3 2020-12-04 14:55:04 +02:00
Vitalii Elenhaupt
0c0ad2a9dd
Merge pull request #174 from crystal-ameba/bump-crystal-version
Change supported crystal version to >= 0.35.0
2020-12-01 20:22:00 +02:00
Sijawusz Pur Rahnama
122dd8e4a9 Change supported crystal version to >= 0.35.0 2020-12-01 13:13:30 +01:00
Vitalii Elenhaupt
5b4b1e817d
Improve forward compatibility with future crystal version
https://github.com/crystal-ameba/ameba/issues/168#issuecomment-722051876
2020-11-05 10:23:25 +02:00
Vitalii Elenhaupt
de3f16a9dc
Disable Lint/EmptyExpression rule
closes #169
2020-10-23 19:21:39 +03:00
Vitalii Elenhaupt
44290a6a5d
Handle case when compiler reports incorrect node location
fixes #168
2020-10-23 10:41:17 +03:00
Vitalii Elenhaupt
9a42d14a1e
Correct version in readme 2020-10-17 13:45:54 +03:00
Vitalii Elenhaupt
8613c5649f
Link docker hub 2020-08-26 23:05:59 +03:00
Vitalii Elenhaupt
61cd274db7
Update docker org in docs 2020-08-26 22:54:29 +03:00
Vitalii Elenhaupt
2eedcb87bb
Bump 0.13.2 2020-08-26 22:46:32 +03:00
Vitalii Elenhaupt
f8d57345d4
Merge branch 'develop' 2020-08-26 22:46:03 +03:00
Vitalii Elenhaupt
5ee54293a8
Upgrade alpine img
refs #166
2020-08-26 22:42:29 +03:00
Vitalii Elenhaupt
b5bd76dfa8
Useless Assign: ignore variables with '_' prefix
closes #164
2020-08-20 21:15:58 +03:00
Vitalii Elenhaupt
66866a4d6a
Bump v0.13.1 2020-07-16 08:25:58 +03:00
Vitalii Elenhaupt
d650ca5477
Incorrectly reporting shadowingOuterLocalVar within macro included
closes #161
2020-07-15 10:18:12 +03:00
Vitalii Elenhaupt
7f501a1df5
RedundantStringCoercion: do not report to_s with named args
closes #160
2020-06-24 09:26:03 +03:00
Vitalii Elenhaupt
3448de30da
Enable rules which were disabled during bugfix release 2020-06-19 21:41:02 +03:00
Vitalii Elenhaupt
3c90863d9e
Bump 0.13.0 2020-06-19 21:37:47 +03:00
Vitalii Elenhaupt
318fbdc4bf
Merge pull request #157 from crystal-ameba/feat/yaml-serializable
Move to YAML::Serializable
2020-06-18 16:02:59 +03:00
Vitalii Elenhaupt
c3260c1740
Move to YAML::Serializable 2020-06-15 14:29:49 +03:00
Vitalii Elenhaupt
25fd493145
Fix compatiblity with crystal nightly 2020-05-14 11:43:13 +03:00
Sijawusz Pur Rahnama
41b31a9a3e Test against Crystal nightlies 2020-05-05 16:57:28 +03:00
Vladislav Trotsenko
bdeb6e3391
Feature/Layout trailing lines, final newline checkup (#152) 2020-05-05 16:52:24 +03:00
Matheus Richard
f1adf14527
Handle duplicated files on GlobUtils (#151)
* Handle duplicated files on GlobUtils

* Update src/ameba/glob_utils.cr

Co-Authored-By: George Dietrich <yomoejoe@gmail.com>

Co-authored-by: George Dietrich <yomoejoe@gmail.com>
2020-04-19 11:52:15 +03:00
Vitalii Elenhaupt
b215b34060
Disable new rules before the coming bugfix release 2020-04-13 10:11:15 +03:00
Vitalii Elenhaupt
e9bd6057c7
Bump 0.12.1 2020-04-13 10:00:26 +03:00
Vitalii Elenhaupt
478da94c20
Allow constants to be in PascalCase (i.e. Log, SuperConstant)
closes #148
2020-04-13 09:38:05 +03:00
Sijawusz Pur Rahnama
1a25583036
Make InlineComments::COMMENT_DIRECTIVE_REGEX more strict (#146) 2020-04-11 09:55:41 +03:00
Vitalii Elenhaupt
458c492730
Do not report shadowing outer local var is var is declared below the
shadowed var

closes #144
2020-04-10 10:44:42 +03:00