Clojure review

From Microck/ordinary-claude-skills · View interactive version

Clojure review is an AI agent skill from the GitHub repository Microck/ordinary-claude-skills. Review Clojure and ClojureScript code changes for compliance with Metabase coding standards, style violations, and code quality issues. Use when reviewing pull requests or diffs containing Clojure/ClojureScript code.

How to use this skill

Skill file

Clojure Code Review Skill

@./../_shared/clojure-style-guide.md

@./../_shared/clojure-commands.md

Review guidelines

What to flag:

What NOT to post:

Example bad code review comments to avoid:

This TODO comment is properly formatted with author and date - nice work!

Good addition of limit 1 to the query - this makes the test more efficient without changing its behavior.

The kondo ignore comment is appropriately placed here

Test name properly ends with -test as required by the style guide.

Special cases:

Quick review checklist

Use this to scan through changes efficiently:

Naming

Documentation

Code Organization

Tests

Modules

REST API

MBQL

Database

Drivers

Miscellaneous

Pattern matching table

Quick scan for common issues:

| Pattern | Issue |

| -------------------------------------------- | ----------------------------------------------------------- |

| calculate-age, get-user | Pure functions should be nouns: age, user |

| update-db, save-model | Missing ! for side effects: update-db!, save-model! |

| snake_case_var | Should use kebab-case |

| Public var without docstring | Add docstring explaining purpose |

| ;; TODO fix this | Missing author/date: ;; TODO (Name 1/1/25) -- description |

| (defn foo ...) in namespace used elsewhere | Should be (defn ^:private foo ...) |

| Function > 20 lines | Consider breaking up into smaller functions |

| /api/dashboards/:id | Use singular: /api/dashboard/:id |

| Query params with snake_case | Use kebab-case for query params |

| New API endpoint without tests | Add tests for the endpoint |

Feedback format examples

For style violations:

This pure function should be named as a noun describing its return value. Consider user instead of get-user.

For missing documentation:

This public var needs a docstring explaining its purpose, inputs, and outputs.

For organization issues:

This function is only used in this namespace, so it should be marked ^:private.

For API conventions:

Query parameters should use kebab-case. Change user_id to user-id.

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.