Upgrade to Pro — share decks privately, control downloads, hide ads and more …

clj-kondo: a linter for clojure code that sparks joy (DCM May '19)

clj-kondo: a linter for clojure code that sparks joy (DCM May '19)

Bbb17eeeecd3d9d06f4db310ab630a12?s=128

Michiel Borkent

May 08, 2019
Tweet

Transcript

  1. clj-kondo Michiel Borkent @borkdude Dutch Clojure Meetup 2019-05-08

  2. clj-kondo • a linter for Clojure and ClojureScript • static

    analysis: only looking at code, not executing • compiled to binary with GraalVM, runs on Linux and MacOS • runnable on Windows via JVM (but slower startup, so editor integration is not as nice)
  3. Why another linter? • I've been a happy joker user

    since 2017 • Missing some features but not that experienced in Go... • joker only knows about 1 file at a time • clj-kondo knows about multiple files at a time, so it can lint calls that cross namespaces
  4. Features

  5. inline def

  6. redundant let

  7. redundant do

  8. arity error

  9. arity error calling other ns

  10. arity error when calling a lib

  11. arity error when calling Java

  12. arity error when calling let- bound fn

  13. letfn arity error

  14. schema defn arity error

  15. recur arity error

  16. private call

  17. cond

  18. duplicate keys

  19. missing map value

  20. binding syntax

  21. missing test assertion

  22. CLJC

  23. coming soon:
 unused namespace

  24. Project setup

  25. Config

  26. Config

  27. Thanks! • joker • rewrite-clj • CircleCI (best CI ever!)

    • eastwood • clj.native-image • people reporting bugs, false positives and suggesting new features
  28. Thank for listening! Questions, suggestions? @borkdude