DEV Community

Discussion on: The Marie Kondo guide for the clean developer

Collapse
 
ingosteinke profile image
Ingo Steinke • Edited

If you're using Git correctly, then you have a trace of every line of code ever written in your database.

Unfortunately not, as most repositories, at least on GitHub, now default to forcing squash commits when merging feature branches. So if you have tried different possible solutions in your feature branch, only the latest version of your code will make it into the main branch, and GitHub will even tell you that it's "safe to delete" your feature branch now.

I usually keep my original feature branches in my local repository for some time, but I doubt that it's a good idea to rely on git, and even more so, on one central origin like GitHub, GitLab, BitBucket, or your company's official SVN upstream, as the only place to persist your work history.

Besides my official code releases, I save bookmarks in my browser, take notes with a pen on paper in an actual notebook, and use DEV and other websites for technical writing, which helps me to get my ideas in order and possibly get some feedback from others as well.

Everything that doesn't make you happy (or is very useful) must be thrown away.

Concerning Marie Kondo and similar influencers, I have always been fascinated but critical at the same time. Take their ideas too literally, and you'll throw away anything that doesn't make you happy or that you haven't used for one year, including your snowboard after there was no snow last winter, and all the stuff that does not spark joy in your heart despite being necessary to clean your home, repair your bike, or send important documents to the tax office. Like with all the modern "mindfulness" fad, you can find truth and inspiration in concepts like "magic cleaning", but always take it with a grain of salt!

Ironically, konmari.com, which appears to be her official website (is it?) offers visitors to shop for new items! Maybe that's the real marketing idea behind magic cleaning: make people throw away their old stuff, then offer them a shop to replace the magically cleaned items.

Collapse
 
eljayadobe profile image
Eljay-Adobe

I like to retain my feature branches too, for a short while. Where "short while" is about 10 years.

Collapse
 
samuelfaure profile image
Samuel-Zacharie FAURE • Edited

as most repositories, at least on GitHub, now default to forcing squash commits when merging feature branches

Indeed this is bad practice. Rebase is the obvious way to go.

It happened to me in code and in life that I threw away stuff that I actually needed later, so a mistake. But practicing mindful getting-rid-of-my-shit has been amazing, as a whole. That being said, it's good to remember that anything related to self-help is the domain of wolves and scammers.