T* About

Credo v1.0.0 released (on its birthday)

TL;DR Credo is a static code analysis tool for the Elixir language with a focus on code consistency and teaching. Today it celebrates its 3rd birthday and goes 1.0! Get it via Hex and on GitHub.

Happy Birthday 🎉

When Credo originally started, I could never have imagined where it would end up. I was the main contributor to Dogma, the then de-facto standard in linting Elixir source files, when I started building the proof-of-concept that would eventually become Credo.

Dogma was a classical linter in the way ESLint and Rubocop are. In fact, Rubocop had been the inspiration for Dogma, which is where Credo’s story starts:

Although I contributed heavily to Dogma, something that was missing was empathy (the motto “A code style linter for Elixir, powered by shame” hinted at that 😁). It was a great tool at pointing out potential flaws in your code, just like Rubocop was in the Ruby ectosystem, but it had also inhereted Rubocops downsides. While it was good at yelling at you, it was not able to help beginners to understand why the tool wanted them to adhere to specific rules. And you had to define lots of rules yourself in config files, oftentimes exceeding 1,000 lines, defining minute details, e.g. whether you should use tabs or spaces.

I thought: Why can’t the computer (a) explain the issues to me in plain english, providing guidance and examples, and (b) infer a project’s preferred style from what the team has already written.

There was no way to know whether or not it was a good idea to build an analysis tool on these ideas, but I felt at the time that it was worth putting some time in. I also felt that it would not be right to try to change Dogma’s foundation to follow my potentially fruitless vision.

I worked on Credo for roughly 3 months, before releasing the first version to the public on Nov 16th 2015.

At the time I wrote:

I want to emphasize why teaching is such an important part of Elixir’s future. […] It’s not obvious most of the time, but we are still an extremely young community and as such we are still capable to shape how we interact with each other and what the overarching motives should be. […]

Admittedly, there’s always the option to treat coders with mislead egos and inferior qualification as second grade programmers. But how about we teach them how to write better code instead?

That was three years ago. Time flies.

Going 1.0 🌟

Today, three years later, v1.0.0 was published to Hex.

IMHO, there are two paths to 1.0:

  1. You have a clear vision of the features which are part of this first complete package and you work towards that until completion.
  2. Your software is used in production by more than 3 people, which makes it “de-facto 1.0” because people depend on you.

I guess that Credo is somewhere in the middle. With well over 100 contributors, over 100 versions published to Hex and 10,000 downloads each weekday it’s clearly used by more than 3 people, but I really wanted to get some things right before declaring it 1.0 (while also avoiding ending up with something like v0.60.0).

1.0 is great milestone for Credo: This stable release gives every contributor the room to explore new directions and experiment with things like caching, building a plugin system, stateful servers and providing better accessibility. The possibilities are - as they say - never ending: We can now start building out an ecosystem of custom checks and provide ways to share those checks more conveniently, as well as establishing additional APIs for check and plugin developers.

In closing, I would like to add: Credo is the most successful project of my Open Source career, which started roughly 9 years ago with tipsy.hovercard. I feel very blessed to be able to be a part of this community, meet so many great people and learn so many new things. Open Source changed my life in so many ways and the spirit of sharing knowledge and open discussion informed so many of my decisions outside of coding.

To the next three years!

Your turn: Liked this post? Retweet this post! 👍