Skip to content

Releases: adobe/elixir-styler

v0.9.6

02 Oct 19:16

Choose a tag to compare

Breaking Change

  • removed mix style task

v0.9.5

22 Sep 16:44

Choose a tag to compare

Fixes

  • fix mistaking Timex.now/1 in a pipe for Timex.now/0 (#66, h/t @sabiwara)

Removed style

  • stop rewriting Timex.today/0 given that we allow Timex.today/1 -- too inconsistent.

v0.9.4

18 Sep 13:31

Choose a tag to compare

Improvements

  • if statements: drop else clauses whose body is simply nil

v0.9.3

15 Sep 15:21

Choose a tag to compare

Fixes

  • fix unless a do b else c end rewrites to if not flopping do/else bodies! (#77, h/t @jcowgar)
  • fix pipes styling ranges with steps (a..b//c) incorrectly (#76, h/t @cschmatzler)

v0.9.2

15 Sep 12:48

Choose a tag to compare

Fixes

  • fix exception styling @def module attributes (we confused them with real defs, whoops!) (#75 h/t @randycoulman)

v0.9.1

15 Sep 12:48

Choose a tag to compare

The boolean conditionals edition!

Improvements

  • auto-fix Credo.Check.Refactor.CondStatements (detects any truthy atom, not just true)
  • if/unless rewrites:
    • Credo.Check.Refactor.NegatedConditionsWithElse
    • Credo.Check.Refactor.NegatedConditionsInUnless
    • Credo.Check.Refactor.UnlessWithElse

v0.9.0

12 Sep 13:50

Choose a tag to compare

Improvements

  • Added right-hand-pattern-matching rewrites to for and with left arrow expressions <-
    example: with map = %{} <- foo() => with %{} = map <- foo
  • with statement rewrites, solving the following credo rules
    • Credo.Check.Readability.WithSingleClause
    • Credo.Check.Refactor.RedundantWithClauseResult
    • Credo.Check.Refactor.WithClauses

v0.8.4

10 Aug 18:33

Choose a tag to compare

Fixes

Timex related fixes (#66):

  • Rewrite Timex.now/1 to DateTime.now!/1 instead of DateTime.utc_now/1
  • Only rewrite Timex.today/0, don't change Timex.today/1

v0.8.3

07 Aug 17:07

Choose a tag to compare

Improvements

  • DateTime rewrites (#62, ht @milmazz)
    • DateTime.compare => DateTime.{before/after} (elixir >= 1.15)
    • Timex.now => DateTime.utc_now
    • Timex.today => Date.utc_today

Fixes

  • Pipes: add ===, !==, and, or, != to list of valid infix operators (#64, ht @ugurtepecik)

v0.8.2

07 Aug 17:07

Choose a tag to compare

Fixes

  • Pipes always de-sugars keyword lists when unpiping them (#60)