Code feels impossible to maintain
At some point, you can feel like you hit a point of no return.
The codebase is so big, with so many issues that it's just impossible to do anything! It's really tempting to just trash it and start over… But is it the best thing to do? What else can you do?
🎓 Related articles
- Find how to (re)organize code with git
Does your codebase feel like a tote bag of "shared" and "utils" folder? Git may help you find a better structure.
- Can AI help me refactor legacy code?
Can assistants like ChatGPT refactor existing code without introducing bugs? Let's figure it out with an actual codebase.
- 7 advice to help you inherit a legacy codebase
My recap of the most common and useful advice one can give to tackle Legacy codebases.
- The key points of The Legacy Code Programmer's Toolbox
This book is full of tips to get into an unfamiliar codebase. Here's my summary of its salient points.
- Start cleaning your Legacy codebase with The Daily Refactoring Hour
Building the habit of small refactorings as you go will make a difference in the long run.
- Identify who to ask for help with Knowledge Maps
Learn to draw a Knowledge Map of your codebase within minutes, and find out who owns what!
- Quickly improve code readability with Proximity Refactorings
Here's a technique that leverages how your brain works to make any code easier to work with.
- The key points of Software Design X-Rays
This book is a gold mine. Yet, it's not a famous one. Here's my summary of its salient points that can help you deal with large codebases.
- 7 techniques to regain control of your Legacy codebase
Working with Legacy Code is no fun… unless you know how to approach it and get your changes done, safely.
- Convince managers to address Tech Debt with Enclosure Diagrams
How to come up with a plan that will resonate with non-technical people, in 7 concrete steps.
- Bring Legacy Code under tests by handling global variables
What's the best way to deal with these annoying global variables? Make them explicit.
- Earn future maintainers esteem by writing simple ADRs
With Legacy Code, there is never any good documentation. Hopefully, there's a simple way for you to stop that trend.
- Focus refactoring on what matters with Hotspots Analysis
Here's a way to prioritize refactoring when you have to deal with a large, unmaintainable codebase.
- The Ship of Theseus to NOT rewrite a legacy system from scratch
When an application becomes impossible to maintain, a rewrite is very tempting. But it could make things worse.