Information age society tends to grab most of, if not all, the time you have at your disposal, and often still asks for more. Since time is your most important resource, you need to manage it aptly, and - surprise - if you are an independent (that is, you work on your own) coder, you can do that.
If the past 12 years of coding on my own, I enjoyed good and suffered bad times. I hereby summarize some practices which work well for me, and which should help you increasing the good moments and decreasing the bad ones.
- Try to work in a peaceful environment: a lonely place, or with a few people, would be ideal.
- Never miss to exploit the moments when you feel you want to code, even if it's late night: inspiration can be rare, so take the most from your best moments. You can always sleep during daytime...
- If some days you feel like you won't be able to do anything useful, by all means don't, otherwise you'll have the same problem the following days. Go out for a walk, find inspiration, relax.
- Don't use instant messengers!!! Even though they're nice (and even useful at times), they tend to seize you attention all the time (and, depending on the content of the messages, can even upset you :-)). I find it a lot better to have an IRC chatroom open (i.e. the one where you ask/give coding help) and look at it every now and then.
- Check for new mail not any more often than every hour, or you won't be able to concentrate. Disable the 5-minute checks in your e-mail client, or at least disable visual and acoustic notifications of new e-mails.
- Take pauses while coding. This means: do not look at the screen for a long period of time if your eyes tend to suffer (pain, blurred vision, floaters, ...). You can take a break every now and then to read something (on paper!), get some water, prepare a cup or coffee, ... This will help you to remain relaxed and more productive.
- Avoid ring tones on your mobile phone (provided you keep it switched on): a sound which often interrupts you can quickly become upsetting. Use vibration instead.
- Switch off your computer when you go to sleep: when I used to keep mine switched on 24h/24, too many times I remembered to do "something" when I was about to go to bed, and that led me to go back to the PC (it's in the basement) and then stay there at least another couple of hours doing nothing really useful. By switching the computer off, I that I do this only if I have to do a very important thing, which happens almost never.
- Take at least one month of vacation per year, but not altogether! 1 month is just 8% of the year, so if you work well you deserve it. However, if you stay away for 1 continuous month, when you can back you'll find yourself into a nightmare of e-mails, phone calls, etc - so it's better to take shorter breaks more often. If you don't want to travel, beware that holidays at home always mean "some work": if it's acceptable for you, a good idea can be to allow a couple of hours in the evening to keep up with email, etc...