5 ms·
My current setup: I work in tmux (similar to GNU screen) on a server. I reattach to the session with `tmux a`, and detach with ctrl-b-d. This preserves my tmux
by sempron64 6y ago
My current setup: I work in tmux (similar to GNU screen) on a server. I reattach to the session with `tmux a`, and detach with ctrl-b-d. This preserves my tmux windows between ssh sessions, and this captures my state of work where I stopped some code open, commands running, etc. I have command history and "go back" accessible in vim and my command panes. I find this is the best way to jump back in. I reboot weekly, after which I have to re-arrange my work area, but once a week is OK.
I find tmux much more effective for this than just arranging windows on my laptop, because ALL the tmux panes are work related, as opposed to windows on the desktop which get littered with email, websites, calendar, chats, etc. This is mentally hygienic for my productivity -- the terminal is where work happens similarly to how the bed is where sleep happens, so it is easy to get back into the flow based on the context.
I don't feel as productive and lose context a lot more when I had to load up an IDE each morning. If you have to use an IDE, I would recommend leaving it on overnight by hibernating the machine or similar, so you have all your code arranged, breakpoints set, navigation history/undo history etc. This helps me remember where I'm at when I start again in the morning. I'll even often leave the debugger at a breakpoint! I also recommend using the terminal within your IDE if it does not suck (I know it does suck in some IDEs). This allows you to keep all programming operations in one context similar to tmux.
- spiffytech 6y agoThis hits on the head a broad pattern in my computer usage: never close something you'll come back to soon. I've known many people who finish the workday by clicking Shut Down on their workstation, and start the next workday with a fresh boot. That is so alien to me; I click Suspend, so each day everything is exactly how it needs to be to continue working, including terminal output, running processes, open windows and their state, etc. This saves me time, and jump-starts my brain by basically loading in the swapped-out mental context I was in yesterday instead of reinitializing the same mental state from scratch.
- mod 6y agoI used to code remotely in a tmux session, and I like all the same benefits you mention. Check out tmuxinator for your once a week "reorganizing" problem. I also found it highly useful as a web dev who worked in many environments with many different languages.
- sempron64 6y agoThank you!
- RMPR 6y ago> I reboot weekly, after which I have to re-arrange my work area, but once a week is OK. You may want to have a look at Tmux resurrect[0] 0: https://github.com/tmux-plugins/tmux-resurrect https://github.com/tmux-plugins/tmux-resurrect
- sempron64 6y agoThank you!