I create a log for almost every day that I code, and have done so since December. I do this to keep track of my progress mostly, so that I can see how far I've come, and also to stop myself from thinking I can't do it. Programming is hard, and it's important to reflect on how much we learn while programming, because it helps us realise how far we've come, and reminds us of all the efforts we've put in.
Often, we think others know a lot more than we do, or that they are naturally better at programming than we are. What we don't see, however, is the efforts they put in, the failures they encountered, the hardships they faced. We usually see the effortless part of programming, and feel demotivated when it doesn't feel the same when we do it.
By logging my work every day, I can physically see what I did during the last three months, and how far I've come. It helps me realise that little by little, I'm growing and getting better, and it has helped me become more confident in my coding abilities. I'm writing about logging today in the hope that it helps others who, like me, may be struggling to see what they've achieved.
Logging is simply recording some information that you want to keep track of. A log is a file in which you've written down what mattered to you, in a format that you find useful. I will be detailing how I record my logs further down, so keep on reading!
By logging what you do every day, you can see how much you've learnt since you started logging. It makes it easy to see when you learnt something, how long ago that was, and it is also pretty nice - if you log regularly - to see how much time, work and effort you have put in.
When I have a problem with my code, I sometimes write it down in my log. This forces me to think of a way to explain my problem clearly, which helps me find a solution faster. Just like rubber ducking! And if I need to ask someone, then I am sure that I can express my problem well enough that the person I asked can help me.
Once I've written down my problem, I'll write down the solution to that problem so that when I encounter it again, instead of Googling everything all over again, I can just find it in my logs and fix it faster.
I keep a list of links to blog posts, Stack Overflow answers, Safari O'Reilly books, etc. that have helped me solve a problem or taught me more about a topic. That way, I have those links within the context of the problems I was trying to solve, so that I can refresh my memory if I need to revisit them.
Often, I will come across a new idea, concept, or technology that I want to learn more about, but don't have the time for when I'm working. So I write it down in my log, and dig it up later when I have time for it.
I have been using the following template for a few months, and it works well for me. The beauty of logging is that you can make it your own and decide what you want to keep track of, so if something does not help you, change it!
# Codelog #X - XXXX-XX-XX ----- ## Plan for the day ----- ## To investigate ----- ## Learned today ----- ## Done today ----- ## Plan for tomorrow ----- ## Resource list
With "Plan for the day", I set my intentions for the day and decide what I will be working on, which keeps me accountable and helps me set goals. "Plan for tomorrow", on the other hand, is where I will put the overflow of tasks I may not have been able to complete on a given day, or I will set intentions for the next day, which I will review when I start my log on that day.
I keep track of what I want to read about in "To investigate", I keep track of my issues and their solutions in "Learned today", and I keep track of the useful links I have found in "Resource list".
Here is an example of a completed log:
I used to keep my log on my blog, but I have since moved them to their own repository as there were too many of them and it was getting difficult to keep track.
EDIT: If you want your own logs repository, I have created a template repository for you to use as you wish.
You can keep track of your logs in a Word/Google Docs document, or in a note-taking app, or in a notebook, or on your website, or anywhere you want! Just make sure it is easy to find and navigate for when you need to look back through what you have.
After a while, you will see your log collection grow. You will be able to revisit your logs and remember times when you solved a tricky problem. You will be able to find the answers to a problem you already had much faster, and you will not be able to tell yourself that you can't do it, or that you are not smart enough, or that you don't know enough.
Because you can do it, and you are smart enough, and learning is a lifelong process! So best of luck with logging, and I hope you find it as useful as I have!