This question is more about organizing the directories/files on my computer. However, this IS a problem every programmer runs into so I thought it appropriate to ask here.
Over the least few years I’ve worked on many projects on many platforms (classic asp, asp.net webforms, asp.net mvc, rails, etc). Most of them are websites but some are not. These projects not only have source code but also some photoshop files, word documents, spreadsheets, etc.
I also like to clone interesting git repos I find on github.com and download source code from sourceforge.net.
My question is, how do I organize these files in a way that makes sense? Right now I have something like this:
/sourcecode
/non_web_projects
...
/websites
/classic_asp
/project1/website # the source code
/project1/misc # everything else
/project2/website
/project2/misc
...
/asp_net
/project1/website
/project1/misc
...
/asp_net_mvc
/project1/website
/project1/misc
...
/rails
/project1/website
/project1/misc
...
/git_repos
...
/source_forge
...
But I feel this is a big mess. How do you guys organize your projects, source code, and related assets?
I keep all my active projects, regardless of type, directly in ~/Projects. Periodically I run this ruby script which gives me the option to either archive or junk old projects. This combination works pretty well to keep me focused on what’s going on.
On caveat, I will keep projects in different places based on who the projects are for and what computer I’m on. On my personal systems I keep personal projects in ~/projects and projects for others, such as my employer in ~/client_name_here/projects. On my work computer I keep work related projects in ~/projects and that’s it.
For me it is all about navigation. Getting into the correct directory should be as painless as possible. That’s why I keep everything directly off of ~/Projects. I have ~ in my cd path so no matter where I am on the file system I can type cd Pro and I’m in my project folder. From there it’s just a matter of cd-ing into the correct project directory.