You are hereBlogs / Slim's blog / Directory Structure and Naming Conventions for Web Development
Directory Structure and Naming Conventions for Web Development
On my path to becoming a better developer. This is the directory structure and file naming conventions to implement a website with Drupal 6. We will map the directories in another message.
Mercurial web store directory structure
the mercurial web store directory
/var/www/hg_store/
my drupal base mercurial store where all the base files for drupal 6.x are held
/var/www/hg_store/drupal-6/base
my drupal all store where common modules for all my sites are stored
/var/www/hg_store/drupal-6/all
the directory for mercurial tracked websites
/var/www/hg_store/drupal-6/websites
my drupal default store where the skeleton for website specific files, modules, and themes are held:
/var/www/hg_store/drupal-6/websites/skel
Workspace
This is the place where I build and configure a drupal site from store for development on dev server.
The directory for my development workspace:
/var/www/workspace
the directory to house drupal sites within drupal application
/var/www/workspace/drupal-6/sites
the drupal sites/all directory where common modules across many drupal sites are shared
/var/www/workspace/drupal-6/sites/all
Stage
This is where the final copy of the site is before syncing it with the production copy on client account without the mercurial store. This is created with the command "hg archive".
/var/www/stage/
The directories are generated at the end of development cycle and very unstable. These directories are to prep for the syncing on clients host.
Naming conventions
The naming of the websites are the FQDN
Example for llslim.com
/var/www/hg_store/websites/llslim.com/
The naming convention for staging is the base name and revision
Example:
hg archive /var/www/stage/%b-%R
Now these naming conventions may change over time, but here are the basics. Next will be the mapping of directories.