<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Stuck Together With Tape &#187; Hacks</title>
	<atom:link href="http://www.stucktogetherwithtape.com/blog/category/hacks/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.stucktogetherwithtape.com/blog</link>
	<description>Just another WordPress weblog</description>
	<lastBuildDate>Fri, 12 Nov 2010 22:38:44 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>Sync Web Dev with MAMP and Dropbox</title>
		<link>http://www.stucktogetherwithtape.com/blog/2009/12/sync-web-dev-with-mamp-and-dropbox/?utm_source=rss&amp;utm_medium=rss&amp;utm_campaign=sync-web-dev-with-mamp-and-dropbox</link>
		<comments>http://www.stucktogetherwithtape.com/blog/2009/12/sync-web-dev-with-mamp-and-dropbox/#comments</comments>
		<pubDate>Thu, 10 Dec 2009 20:00:02 +0000</pubDate>
		<dc:creator>Jim</dc:creator>
				<category><![CDATA[Hacks]]></category>
		<category><![CDATA[apache]]></category>
		<category><![CDATA[cloud]]></category>
		<category><![CDATA[dropbox]]></category>
		<category><![CDATA[mamp]]></category>
		<category><![CDATA[mysql]]></category>
		<category><![CDATA[web dev]]></category>

		<guid isPermaLink="false">http://www.stucktogetherwithtape.com/blog/?p=103</guid>
		<description><![CDATA[Dropbox Initially I used dropbox, as an alternative to email, to share music tracks and ideas with band mates. So simple even our singer could work it out! It has quickly become my main tool for syncing all sorts of other data. So I decided to see if it could be used to sync multiple [...]]]></description>
			<content:encoded><![CDATA[<p style="text-align: center;"><img class="size-full wp-image-119 aligncenter" title="dropbox-mamp" src="http://www.stucktogetherwithtape.com/blog/wp-content/uploads/2009/12/dropbox-mamp.png" alt="dropbox and mamp" width="460" height="320" /></p>
<h3>Dropbox</h3>
<p>Initially I used <a href="http://www.dropbox.com/">dropbox</a>, as an alternative to email, to share music tracks and ideas with  band mates. So simple even our singer could work it out! It has quickly become my main tool for syncing all sorts of other data.</p>
<p>So I decided to see if it could be used to sync multiple MAMP web development environments. Site files and MySQL databases.</p>
<p><span id="more-103"></span></p>
<p><a href="#thegoodshit">Ok, skip the blah, show me the method!</a></p>
<h3>Syncing Applications with Dropbox</h3>
<p>When you work on multiple computers it can be a pain to keep things in sync. But, where there&#8217;s data there&#8217;s a way to sync it with dropbox. One of the first dropbox solutions I came across was for <a href="http://agilewebsolutions.com/products/1Password">1Password</a>, my password manager of choice. 1Password holds all its data in a keychain so you can simply move the <em>1Password.agilekeychain</em> file to your dropbox and edit preferences in 1password to point to the new location. A more detailed tutorial can be found over at <a href="http://webworkerdaily.com/2008/09/29/1password-dropbox-sync/">WebWorkerDaily</a>. As of <a href="http://agilewebsolutions.com/products/1Password/whats_new">version 3</a>, this keychain file can also be opened as an HTML webpage so you can access your passwords on computers without 1password installed.</p>
<p><a href="http://culturedcode.com/things/">Things</a> requires a different approach. There is no preference option to chose the location of you data file. Instead you can move the Things data folder into your dropbox and create a symbolic link in its place. Detailed instructions can be found at this <a href="http://hocuspokus.net/2008/11/sync-your-things-database-via-dropbox">hocuspokus.net</a>. Symbolic links are basically low level Aliases. I also use a similar method to keep the <a href="http://www.tipsfor.us/2008/11/24/keep-your-address-book-in-sync-with-dropbox-mac-os-x/">address book app in sync</a>.</p>
<p>After using dropbox to sync these apps between 3 computers I was in need of a better way to sync my web development projects. I was already using dropbox to share zipped versions of site files and mysql dumps but this process was a bit tedious. Every morning I have to unarchive the files into my sites folder and re-import databases and remember to export them before I left. One solution would be to create a couple of scripts to import and export this data&#8230; but after seeing how well dropbox had worked so far, I decided to test its limits and sync a whole web development sever.</p>
<h3 id="thegoodshit">Syncing MAMP with Dropbox</h3>
<p>I use <a href="http://www.mamp.info">MAMP</a> to run my local webserver with php and mySQL. The first step is to sync Apache&#8217;s webroot. By default it&#8217;s located in the <em>/Applications/MAMP/htdocs</em> folder.</p>
<p>Click Preferences &gt; Select the Apache tab and change the location to a folder in your dropbox, I use /<em>Dropbox/Sites</em>.</p>
<p><img class="aligncenter size-full wp-image-121" title="apache-settings" src="http://www.stucktogetherwithtape.com/blog/wp-content/uploads/2009/12/apache-settings1.png" alt="apache-settings" width="600" height="265" /></p>
<p>Now all your development site files will be kept in sync through your dropbox.</p>
<p><img class="size-full wp-image-118 alignright" title="create-symbolic-link" src="http://www.stucktogetherwithtape.com/blog/wp-content/uploads/2009/12/create-symbolic-link.png" alt="create-symbolic-link" width="320" height="430" /></p>
<p>The second step is to sync MAMPs MySQL server. Unfortunately MAMP does not provide the option to define the location the database files are kept. So I followed the symbolic link method used to sync Things.</p>
<p>MAMPs database files are stored in <em>/Applications/MAMP/db</em>. Make sure you quit MAMP first, then move the db folder to your dropbox.</p>
<p>Create a symbolic link back to its original location. You can use terminal for this but I prefer to use <a href="http://www.macupdate.com/info.php/id/10433">SymbolicLinker</a> a contextual symlink plugin. It gives you a &#8220;Make Symbolic Link&#8221; option in any file or folders right click menu.</p>
<p>Thats it, you&#8217;re done. Start up MAMP and you&#8217;re up in the cloud.</p>
<h3>Steady Eddy</h3>
<p>I haven&#8217;t tested this process fully yet and may update this post if I see any trouble brewing. A few points to note though.</p>
<ul>
<li>Developing large sites with large databases is gonna fill up your dropbox pretty quickly.</li>
<li>I wouldn&#8217;t recommend developing on different computers simultaneously, dropbox is quick but not that quick. I can imagine your database could get messed up if your jumping between computers updating and deleting records. But by all means give it a go and let me know how dropbox copes!</li>
<li>For theses reasons do not totally rely on dropbox. It&#8217;s always good practive to have a local backup of your dev files as well, just incase.</li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://www.stucktogetherwithtape.com/blog/2009/12/sync-web-dev-with-mamp-and-dropbox/feed/</wfw:commentRss>
		<slash:comments>16</slash:comments>
		</item>
	</channel>
</rss>

