Support » Installing WordPress » Mac Leopard Theme Dev Workflow

  • Hi all. I’ve been using a local install on my Mac for development, working out of the /Library/WebServer/Documents/. I’ve had Apache set up with a virtual host to mimic a live site. All is fine (beyond the mess I’ve created in the config files of course).

    Anyway, I’d like to improve things and work on multiple themes and sites at the same time, and make better use of the available tools (Subversion, CSSEdit, et al). At present I’m doing a lot of fumbling and file copying.

    To get to the point: I’m a little creeped out by using Subversion working copies and doings lots of editing in the Library root, and think I’d be better off working from my personal Sites folder. Does that sound rational? I picture a bunch of installs inside my Sites folder, next to whatever other web things i’ve got going on.

    The main problem is I don’t really know how to do it, either from an installation standpoint, or Apache setup. Do I have to make my Sites folder the document root, and lose the Library root? Any tips? TIA.

Viewing 1 replies (of 1 total)
  • Mike,

    I think it’s safe to say many, if not most, experienced web developers using Mac OS X are using their Sites folder as their DocumentRoot. To do this, you simply need to edit your Apache httpd.conf file (/private/etc/apache2/httpd.conf) and set the two options (DocumentRoot “/Library/WebServer/Documents” and <Directory “/Library/WebServer/Documents”>), typically within 30 lines or so from each other, to something like /Users/MikeLesser/Sites.

    I’ve used this setup for years and have had no trouble with it. However, as of late, I’ve come to prefer using MAMP as my development environment ( Why? Because it leaves the default OS X settings alone and creates a separate install of Apache, PHP and mySQL with minimal changes needed. MAMP has its own httpd.conf file to adjust and you can basically screw around with it as much as you like without compromising your OSX Apache install. The only time you’ll need to edit something in the primary Apache install, is to the hosts file if you want to do virtualhosting – very handy if you develop with content mgmt systems.

    My suggestion is to copy or move your development sites out of the default location and put them into your Sites folder, then start using MAMP and point it towards your Sites directory. If you need to reinstall a fresh OS later down the road, as long as you’ve saved your MAMP preferences (kept in the Applications > MAMP folder) and your User folder, you’ll always be able to get up and running right away again.

    For Subversion, there are many options of where to keep your repository, whether online or local. Myself, I have a local repository which I use to manage my Sites folder, so I can keep track of incremental changes, and if necessary, revert to them. Then, twice a month I backup my work onto an external drive using SuperDuper. This way, I can take my external drive with me anywhere, and it will function as a duplicate of my machine, svn revisions and all. I keep this backup drive at work in case my home is broken into, fire, etc. This Subversion setup is only useful because I am the only one working on my files. If you collaborate with others, it’s probably better to have a remote repository.

    This setup has served me well, but of course, there are other variations.

Viewing 1 replies (of 1 total)
  • The topic ‘Mac Leopard Theme Dev Workflow’ is closed to new replies.