I'm in the middle of a large freelance project. Everything was going well until I had realised that I painted myself into a corner. I had thought that the way that I had organised my modules was pretty good. Now that I took a step back and looked at it again, I found it to be a complete mess. If any other programmer were to look at it I'm sure that they would run away and seek mental help immediately from the trauma of looking at it.

My first thought of what to do would be to go through all the modules and clean it up as good as I could. My second thought as to what to do is to ask myself "Am I doing this the right way?".

When you start a large project where you are the only individual programming it from start to finish. How do you prepare for it? How do you organise your modules? And if you find yourself between a rock and a hard place. What do you do?