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.

How do you keep the files you are working on in your head when programming?

3 pointsby dickjockeabout 5 years ago
I find that this is the biggest pain point for me. When I am working on a task, it usually ends up spanning several files. And I just don&#x27;t have very good memory.<p>I struggle to remember if I had some new variable in the Logger or the Worker, etc. It&#x27;s usually trivial to see the list of files I&#x27;m working in and check between a couple, but I&#x27;d love to know if anyone has a memory palace kind of technique they use for programming.

2 comments

thephyberabout 5 years ago
I think 2 things are helpful.<p>(1) Know that your memory and concentration will suffer if you are distracted or have lots of context switching. Try and change your coding environment (IRL) to suit this fact.<p>(2) Make sure you are using the tools provided by a good IDE. Many IDEs will autocomplete variables&#x2F;functions&#x2F;modules which are in scope of where the cursor is. Make sure you have convenient+relevant IDE extensions&#x2F;plug-ins for your language+libraries running.<p>There are exercises you can do to increase your memory, but I think your programming ergonomics are bad if you have to resort to that.
gregjorabout 5 years ago
vim buffers and splits. And a paper notepad and pen.