Jenkins< > >
Your company might already use Jenkins .
I'd guess the likelihood increases with the age of the company you're working in.
I must say I've had more bad experiences with it than good.
That's not because Jenkins is terrible but because it was always self-hosted.
Unless you're in the business of task automation for developers, you probably shouldn't host these things yourself.
Pay a company to do it for you.
CircleCI< > >
CircleCI is great.
I've never had any issues with it.
They have a nice GitHub integration, and their support is always responsive.
The only disadvantage I could think of is that all your jobs and all your workflows need to go into the same file.
So, this file will grow over time, and it will become harder to maintain it.
GitHub Actions< > >
GitHub Actions are extremely powerful.
You'll need to host your code on GitHub to use them.
The most irritating thing that I encountered was that you don't want to build what GitHub calls an "action" in most cases.
You want to create a workflow .
Creating your action will probably be a sporadic activity.
More likely, you'll use actions that others have built already .
It took me way longer than I'd like to admit to figure this out.
And if you don't figure it out, you're set up for a pretty complicated ride.
In contrast to CircleCI, each workflow will live in its file, which makes it easier to create workflows with concise concerns .
However, you'll need to redefine tasks like install
that might be the same for each workflow (or you'll create an install action).
Also, don't trust the "But we all use the prettier
plugin for [IDE] ."
Someone won't, or someone will have it configured in the wrong way.
The last project where I got this answer had violations in 1500 files, and everyone was sure all code was formatted correctly.
You should have this check in your pipeline for when the tool itself is updated.
They might have changed a rule.
In this case, you should probably reformat the whole codebase inside the PR that introduces the update.
Zero lint errors or warnings<
">lint errors, and I'd say you also should not have any warnings.
If you allow warnings, you're going to end up with pointless discussions around whether an error should be a warning or a warning should be an error, or which warnings are safe to ignore.
Save yourself time and fix all warnings and errors.
I would also suggest that you agree on a set of rules that make sense in a way that there is a good reason for them to be there.
I'll give you an example.
Good Rule< > >
Every link that has target="_blank"
set must also define rel="noreferrer noopener"
I consider this a good rule because it statically checks for a genuine threat.
If you don't set these attributes, you open up your page to one of the most prominent attacks on the internet .
Bad Rule< > >
Imports must be sorted alphabetically
The order of imports does not have any effect on your code.
Rules like this one are the personal preferences of some individuals.
If you want to enforce them, look at the section about automatic code formatting.
Put this stuff in there.
Don't make developers actively think about these things.
🙏 This. 🙏 Is. 🙏 Not. 🙏 Important.
A check for cyclic dependencies<
">madge
, which saved my ass countless times.
The biggest issue with cyclic dependencies is that they don't always immediately lead to trouble, and they are ticking time bombs in your codebase.
And who likes these?
Automated tests<
">here , here , and here so I'll keep this short.
Testing means understanding.
If you think you don't need to understand what you're doing before doing it, go ahead.
I really doubt that this makes anyone any faster.
The only thing you get is the illusion of speed because you don't know what you're missing.
I don't think there is any reason not to start with tests right away.
It doesn't harm a prototype to work reliably.
If your software doesn't break all the time, that makes you fast.
If your code is that complex , please, add these tests!