Wednesday, September 29, 2021

A letter for you

I have been tasked to deliver this letter from our dear friend.

Monday, September 20, 2021

Oops I did it again!

When you are working on even a small project for more than one day, you are risking loosing your work if you don't take preventative measures. Over the years I've encountered many horror stories from people losing their work.

Like working on their school thesis for months only to loose their only copy which was on a USB stick. Or to have their hard drives crashed after months of working on a computer game project or thinking their computer was infected by a virus.

They never learn and always take the wrong lesson (be careful about your belongings, don't visit suspicious web sites).

I should really know better. And yet I did it again. After having practically finished Text Editor port to libui (wich took me around a week) I accidentally deleted it.

I had the source only in git cache + a backup copy in a patch file and when I wanted to put the changes away in a patch to work on / commit prompt dialog first, I re-generated the patch and then removed changes from my working branch. And then I realized my patch file was empty! It sets me back only by a week, but it's very embarassing! I really should have tracked my work in changesets even if if was WIP and back up on Github, squashing into one commit later.

So it's good to remind ourselves of the risks and the rules how to mitigate them that we should all know, but don't always follow.

The top three risks are
  1. You accidentally delete/overwrite/damage your project
  2. Your computer/storage medium is physically lost
  3. Your computer is broken rendering your data inaccessible
And here's the golden rules when working on a project:
  1. Back up your work!!!
  2. One back up copy is not enough. Use multiple physically separated copies.
  3. Revision control is your first line of defense.