TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Log driven programming (2013)

106 pointsby eric24234over 6 years ago

16 comments

aeosynthover 6 years ago
<a href="https:&#x2F;&#x2F;orgmode.org&#x2F;manual&#x2F;Capture-_002d-Refile-_002d-Archive.html#Capture-_002d-Refile-_002d-Archive" rel="nofollow">https:&#x2F;&#x2F;orgmode.org&#x2F;manual&#x2F;Capture-_002d-Refile-_002d-Archiv...</a><p>&gt; An important part of any organization system is the ability to quickly capture new ideas and tasks, and to associate reference material with them. Org does this using a process called <i>capture</i>.
评论 #18166568 未加载
DanielBMarkhamover 6 years ago
I use postits for this.<p>I used to use TODOs, but then if I wasn&#x27;t looking at the code I forgot about it, and a lot of the stuff didn&#x27;t have a spot it needed to go. It was just stuff I thought about while I was doing something else.<p>Daily (or twice daily) I reorder and prioritize. Every week or two there&#x27;s a postit cleanup party where old postits get trashed or logged. A lot of the stuff that I trash isn&#x27;t bad....it&#x27;s just not in scope for the stuff I&#x27;m currently doing.<p>ADD: One of the beauties of postits on my monitors is that when my mind wanders -- as it tends to do -- I&#x27;m naturally looking at other stuff I should be thinking about. So when I postit stuff and put it somewhere in my field of vision, I&#x27;m telling my subconscious to start working on what I want to do with this stuff.
raytracerover 6 years ago
A couple of years ago I started using TODO:HIGH, TODO:MED and TODO:LOW.<p>TODO:HIGH is for things that need to be completed for the current feature or bug fix.<p>TODO:MED is for things that should be completed before the next public build.<p>TODO:LOW is for stuff that would be good to get done eventually. (A function is complete but doesn&#x27;t read well so I&#x27;ll add a note to refactor it at later date.)<p>When writing new code I try to get something up and running ASAP by filling in functionality with broad strokes. I&#x27;ll go back and fill in the details once the larger picture is in place. With less code written, it&#x27;s easier to refactor (or restart), if the design is not quite right.<p>Writing lots of TODOs helps ensure nothing gets forgotten about.<p>Picking an easy TODO from the backlog can be good way to warm up when starting the day too.<p>I&#x27;m used to working solo however. Not sure how this approach would go down on a team.
评论 #18166444 未加载
评论 #18167531 未加载
评论 #18172273 未加载
barrkelover 6 years ago
This is my workflow and has been for the past 10 years or so.<p>Whenever you think of something else that needs doing, write it down so you stop feeling the need to keep it in mind.
评论 #18165821 未加载
Fellshardover 6 years ago
Ostensibly, this is what TODO comments have always been for.<p>Realistically, I guess it&#x27;s probably better that these types of comments remain out of the code itself unless you and your team can practice proper rigor around them, e.g. using prehooks to enforce that no TODOs are left around before committing or merging.
评论 #18165646 未加载
评论 #18166380 未加载
keyleover 6 years ago
Yep, a notepad with a direct step by step 1 liners is very effective to get a ton done in one day.<p>Have it between you and the keyboard so it can&#x27;t be ignored, presumably not ruining your typing experience.<p>Straight up notepad or sublime works too.
评论 #18165797 未加载
bvincover 6 years ago
I find it best to put a TODO file in the project that I&#x27;m working on. Sometimes I commit it, sometimes I hide it from git. I think it&#x27;s a big advantage to have it all in one place, not very far from the code, and it won&#x27;t get lost.<p>TODOs in comments end up getting forgotten about. Bug ticketing systems are too much work for the kind of notes I write to myself. I&#x27;ve tried using paper, but as I turn pages, notes on previous pages get lost forever. Staying in the text editor helps me not lose my flow.
jolmgover 6 years ago
&gt; For my log I use Evernote because the log needs to have one characteristic: No save, No filenames, Nothing more than typing something.<p>I got emacs configured with a keybinding to open org files by date name (e.g. 2018-10-08.org), with the current date selected by default, creating them if they don&#x27;t exist. I use `(org-read-date)` so I can, for example, get yesterday&#x27;s notes with syntax like &quot;-1d&quot; or select it from a 3 month calendar. It frees me from having to think of a name for the notes I want to take and simply make a log of notes. It also autosaves.<p><pre><code> (defun find-diary-file () (interactive) (find-file (concat &quot;~&#x2F;org&#x2F;diary&#x2F;&quot; (org-read-date) &quot;.org&quot;))) (global-set-key (kbd &quot;C-c d&quot;) &#x27;find-diary-file)</code></pre>
Dowwieover 6 years ago
For those unaware, the author of this article (Salvatore Sanfilippo) is a prolific programmer and leader in open source. He&#x27;s been very productive in this role, authoring systems that many use today, such as Redis.<p>Obviously, Salvatore didn&#x27;t invent a new creative workflow that he&#x27;s branded &quot;log driven programming&quot;. His intent with this article more likely was to share with others how he works productively. I can imagine that people asked him how he gets so much work done, considering how complex programming is, especially low level systems programming in C.<p>While the article was written in 2013, it shares timeless advice.
cyborgx7over 6 years ago
Had the same idea as I noticed that working in a nested way slowed me down a lot. Been trying to do this but I often lack the discipline to actually work this way and not dive into the local improvement I just thought of.
hyperman1over 6 years ago
I use TODO and FIXME for this. This way, it&#x27;s directly anchored to the relevant code. Both the IDE and the build server produce a list when asked.<p>Every project has a readme attached for bigger notes
bzalaskyover 6 years ago
This is essentially the process that Things 3 (I’m not affiliated in any way) for MacOS&#x2F;iOS uses. It separates adding new tasks (for your inbox) from the step of organizing and scheduling them. So if you think of something you need to do, you can use a keyboard shortcut to pull up a prompt quick add it (from whatever app you’re using) and carry on with whatever else you’re working on.
skohanover 6 years ago
I wrote a simple app for myself for this: it&#x27;s basically a text editor with included checklist UI, optimized for a keyboard based workflow. I find it very useful to have a &quot;conversation&quot; with my notes while I&#x27;m developing to avoid going down too many rabbit-holes, and to keep focus on the primary task.
keithnoizuover 6 years ago
I usually just make the additional changes but I&#x27;m pretty good at keeping pretty massive mental models in place while I do so with out interrupting my work flow. If it&#x27;s something truly massive i add a @TODO ... @PRI-N line in the comments.
mosselmanover 6 years ago
How is something as frivolous as taking notes while programming, which many people do, worth a blog post and a mention here on HN? Let alone turning it into some dogmatic principle to work by, by calling it &#x27;log driven&#x27; programming. What is next? Keyboard driven programming? 3-monitor-driven programming?<p>I do this:<p>While programming it pays off to stop and think about the code. I call this, thought driven programming.
评论 #18173010 未加载
评论 #18165803 未加载
评论 #18165842 未加载
评论 #18166238 未加载
评论 #18165852 未加载
评论 #18165679 未加载
评论 #18166396 未加载
评论 #18166577 未加载
评论 #18167138 未加载
评论 #18172251 未加载
评论 #18168112 未加载
评论 #18165814 未加载
basicplus2over 6 years ago
Sliderule