I take a pen and some paper and start drawing weird archaic diagrams, next is preparing a project directory and checking it into the respository. Then I create a concept.txt that contains all things I want to go in, I want not in, and the ways I want them. Then, based on that and said archaic drawings, I start to write the design of the project itself. Module hierarchies, who does what with whom, code abstractions etc.
Of course this is just for my personal projects. When working with other people and/or customers, it is a more complicated plan-and-discuss game to find the outlines and exact needs of the project.
Ordinary morality is for ordinary people. -- Aleister Crowley