<?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>Winn &#187; Mac</title>
	<atom:link href="http://winn.ws/archives/category/development/mac/feed" rel="self" type="application/rss+xml" />
	<link>http://winn.ws</link>
	<description>Standards-based design &#38; development</description>
	<lastBuildDate>Wed, 01 Feb 2012 05:30:15 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
		<item>
		<title>Install Passenger</title>
		<link>http://winn.ws/archives/734</link>
		<comments>http://winn.ws/archives/734#comments</comments>
		<pubDate>Thu, 21 Oct 2010 19:06:57 +0000</pubDate>
		<dc:creator>Greg Winn</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[Home Page]]></category>
		<category><![CDATA[Mac]]></category>
		<category><![CDATA[mod_rails]]></category>
		<category><![CDATA[Passenger]]></category>
		<category><![CDATA[Ruby on Rails]]></category>

		<guid isPermaLink="false">http://winn.ws/?p=734</guid>
		<description><![CDATA[Passenger makes deploying rails apps as easy as putting the file on the server and starting Apache. I have been using passenger for about 4 years and have used it for some very high scale projects.]]></description>
			<content:encoded><![CDATA[<p><img style="float:left; margin:0 8px 8px 0;" src="http://d45jz936mo8n8.cloudfront.net/wp-content/uploads/2010/10/mod_rails.jpg" alt="" title="mod_rails" width="196" height="63" class="alignnone size-full wp-image-737" /></p>
<p>Passenger makes deploying rails apps as easy as putting the file on the server and starting Apache. I have been using passenger for about 4 years and have used it for some very high scale projects. Passenger makes deployments very php like, what i mean by that is you can just drop the files and go. From my experience using Passenger the only time Apache need to be recycled is when adding a new controller or model. Adding actions inside an already existing controller Apache will not need to be restarted, you can simply start using that action.</p>
<p><span id="more-734"></span></p>
<p>The next big seller for me is the documentation on this product it’s been around for some time so there is a large community around “mod_rails / Passenger”. Passenger works on any POSIX-compliant operating system. In other words: practically any operating system on earth, except Microsoft Windows.</p>
<p>Passenger was super quick and easy to install and get a rails application running. Below i have detailed my installation on Mac OSX 10.6.4.</p>
<p><strong>1) First I opened a terminal window and ran the command:</strong></p>

<div class="wp_syntax"><div class="code"><pre class="shell" style="font-family:monospace;">sudo gem install passenger</pre></div></div>

<p><em>(Important note just remember to sudo).</em></p>
<p><strong>2) Now lets install the apache2 module:</strong></p>

<div class="wp_syntax"><div class="code"><pre class="shell" style="font-family:monospace;">sudo passenger-install-apache2-module</pre></div></div>

<p>After running the apache2-module command it will tell you what you can expect from the install process, just hit “Return”.</p>
<p><strong>3) Now lets setup your Apache, the install will provide you with three lines that need to go into your Apache config document:</strong></p>

<div class="wp_syntax"><div class="code"><pre class="shell" style="font-family:monospace;">LoadModule passenger_module /Library/Ruby/Gems/1.8/gems/passenger-3.0.0/ext/apache2/mod_passenger.so
PassengerRoot /Library/Ruby/Gems/1.8/gems/passenger-3.0.0
PassengerRuby /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/ruby</pre></div></div>

<p><strong>NOTE: Don&#8217;t copy and paste mine, be sure to copy the output from the module install in your terminal window.</strong></p>
<p>After restarting Apache you want to check and make sure AllowOverrides are set to all. Now create your rails project or use an existing one.</p>
<p><strong>4) Now we need to setup a VirtualHost in apache, open the httpd-vhosts.conf file and add this:</strong></p>

<div class="wp_syntax"><div class="code"><pre class="shell" style="font-family:monospace;">&lt;VirtualHost *:80&gt;
	DocumentRoot &quot;/var/www/path/to/your/rails/app&quot;
	ServerName local.YourTestDomain.com
	RailsEnv development # &lt;- important to set this here.
&lt;/VirtualHost&gt;</pre></div></div>

<p>Now restart apache once again and then edit your hosts file adding the local domain, once this has been done you can visit your local domain in a browser and you should now see your rail application running. No need to visit “localhost:3000” any more. Any time you create a new controller or model just restart Apache and reload the page.</p>
<p style="text-align:center;"><img src="http://d45jz936mo8n8.cloudfront.net/wp-content/uploads/2010/10/address_bar_url.png" alt="" title="address_bar_url" width="277" height="39" class="alignnone size-full wp-image-740" /></p>
<p>I hope this has helped someone install this great product, i think you will find it very useful in the future for production rails app’s and just at home development. <a href="http://www.modrails.com/index.html">Read more about mod_rails / Passenger here</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://winn.ws/archives/734/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>PHP/MySQL after 2010-005</title>
		<link>http://winn.ws/archives/492</link>
		<comments>http://winn.ws/archives/492#comments</comments>
		<pubDate>Sat, 28 Aug 2010 07:22:27 +0000</pubDate>
		<dc:creator>Greg Winn</dc:creator>
				<category><![CDATA[Command Line]]></category>
		<category><![CDATA[Development]]></category>
		<category><![CDATA[Mac]]></category>
		<category><![CDATA[MySQL]]></category>
		<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://winn.ws/?p=492</guid>
		<description><![CDATA[After applying Security Update 2010-05, some users have reported PHP and MySQL problems, including an inability to connect to MySQL databases. Apple reports that the following procedure resolves the database connection issue: In the Terminal type sudo nano /etc/php.ini (Terminal will ask you for your password) Change: mysql.default_socket = to: mysql.default_socket = /tmp/mysql.sock Press Ctrl-O, [...]]]></description>
			<content:encoded><![CDATA[<p><img src="http://d45jz936mo8n8.cloudfront.net/wp-content/uploads/2011/01/phpicon.jpg" class="codeicon" alt="php" /></p>
<p>After applying Security Update 2010-05, some users have reported PHP and MySQL problems, including an inability to connect to MySQL databases. Apple reports that the following procedure resolves the database connection issue:</p>
<ol>
<li>In the Terminal type sudo nano /etc/php.ini (Terminal will ask you for your password)</li>
<li>Change: mysql.default_socket = to: mysql.default_socket = /tmp/mysql.sock</li>
<li>Press Ctrl-O, then Enter to save</li>
<li>Type sudo apachectl graceful</li>
</ol>
<p>Note that you may need to duplicate the original install php.ini.default file, just simply copy the contents of the file and create a php.ini. (cp php.ini.default php.ini)</p>
]]></content:encoded>
			<wfw:commentRss>http://winn.ws/archives/492/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>I think i am in Stack Love&#8230;</title>
		<link>http://winn.ws/archives/154</link>
		<comments>http://winn.ws/archives/154#comments</comments>
		<pubDate>Wed, 13 Aug 2008 14:50:07 +0000</pubDate>
		<dc:creator>Greg Winn</dc:creator>
				<category><![CDATA[Command Line]]></category>
		<category><![CDATA[Development]]></category>
		<category><![CDATA[Mac]]></category>
		<category><![CDATA[BitNami]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[Stacks]]></category>

		<guid isPermaLink="false">http://www.winn.ws/?p=154</guid>
		<description><![CDATA[I am talking about BitNami Open Source Stacks! This was something i found and started using right away! I dont get &#8220;jump up and down&#8221; happy too often but, this is one of the times! I have been using BitNami for about 3 weeks and i dont know how i got along without it! Trust [...]]]></description>
			<content:encoded><![CDATA[<p>I am talking about <a href="http://bitnami.org/">BitNami</a> Open Source Stacks! This was something i found and started using right away! I dont get &#8220;jump up and down&#8221; happy too often but, this is one of the times! I have been using BitNami for about 3 weeks and i dont know how i got along without it! <strong>Trust me, if your a developer you will love this!!!</strong> Stop wasting your time with installing each item for testing, just use BitNami form now on. You will thank me later.</p>
]]></content:encoded>
			<wfw:commentRss>http://winn.ws/archives/154/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Goodbye .Mac!</title>
		<link>http://winn.ws/archives/152</link>
		<comments>http://winn.ws/archives/152#comments</comments>
		<pubDate>Thu, 10 Jul 2008 21:35:09 +0000</pubDate>
		<dc:creator>Greg Winn</dc:creator>
				<category><![CDATA[Mac]]></category>

		<guid isPermaLink="false">http://www.winn.ws/?p=152</guid>
		<description><![CDATA[Well it&#8217;s the 10th and Apple has taken the .mac site down, i am guessing to prepare for the Mobile Me &#8220;.Me&#8221;. As a .Mac account holder you get the Mobile Me upgrade for free, so i cant wait to check that out!]]></description>
			<content:encoded><![CDATA[<p>Well it&#8217;s the 10th and Apple has taken the .mac site down, i am guessing to prepare for the Mobile Me &#8220;.Me&#8221;. As a .Mac account holder you get the Mobile Me upgrade for free, so i cant wait to check that out!</p>
<p><a href="http://d45jz936mo8n8.cloudfront.net/wp-content/uploads/2008/07/byebye_dotmac.jpg" rel="lightbox"><img src="http://d45jz936mo8n8.cloudfront.net/wp-content/uploads/2008/07/small_byebye_dotmac.jpg" alt="Bye Bye Dot Mac" /></a></p>
]]></content:encoded>
			<wfw:commentRss>http://winn.ws/archives/152/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>AppleScript and me</title>
		<link>http://winn.ws/archives/141</link>
		<comments>http://winn.ws/archives/141#comments</comments>
		<pubDate>Tue, 15 Apr 2008 15:27:28 +0000</pubDate>
		<dc:creator>Greg Winn</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[Mac]]></category>
		<category><![CDATA[Applescript]]></category>

		<guid isPermaLink="false">http://www.winn.ws/?p=141</guid>
		<description><![CDATA[Well, I built m first ever AppleScript application the other day! It will allow users to connect to a server via ssh and then rsync and or scp files from a mac to the server. I was very happy with how it came out looking, the Interface Builder was helpful but most of this application [...]]]></description>
			<content:encoded><![CDATA[<p>Well, I built m first ever AppleScript application the other day! It will allow users to connect to a server via ssh and then rsync and or scp files from a mac to the server. I was very happy with how it came out looking, the Interface Builder was helpful but most of this application had to be done by hand with applescript. I picked it up in less then a week, that’s how easy it is to learn this! It’s very developer friendly! Below is a snippet of code from my latest application.</p>
<p>[code]<br />
if sPath is "" then<br />
  stop progress indicator "spinner" of window "filesync"<br />
  display dialog "Sorry you can't transfer to the root, enter a valid server address"<br />
else</p>
<p>tell application "Terminal"</p>
<p>launch<br />
do script "scp -r " &#038; lPath &#038; " " &#038; uname &#038; "@server:" &#038; sPath &#038; "" in window 1<br />
delay 6</p>
<p>do script uPass in window 1<br />
[/code]</p>
<p>Easy, i am sure i will be using more of this in my web development so i will keep you posted.</p>
]]></content:encoded>
			<wfw:commentRss>http://winn.ws/archives/141/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Install wget on your mac.</title>
		<link>http://winn.ws/archives/139</link>
		<comments>http://winn.ws/archives/139#comments</comments>
		<pubDate>Mon, 07 Apr 2008 18:26:34 +0000</pubDate>
		<dc:creator>Greg Winn</dc:creator>
				<category><![CDATA[Command Line]]></category>
		<category><![CDATA[Development]]></category>
		<category><![CDATA[Mac]]></category>
		<category><![CDATA[Apple]]></category>
		<category><![CDATA[wget]]></category>

		<guid isPermaLink="false">http://www.winn.ws/?p=139</guid>
		<description><![CDATA[Ok, i am not sure why it is not included with the mac bash but i have installed wget for my mac. This is an easy process to do and then to start using! First we need to download the wget files to your Desktop. Download Download wget for Mac OS X (124 KB) Install [...]]]></description>
			<content:encoded><![CDATA[<p>Ok, i am not sure why it is not included with the mac bash but i have installed wget for my mac. This is an easy process to do and then to start using! First we need to download the wget files to your Desktop.</p>
<h4>Download</h4>
<p><a href="http://d45jz936mo8n8.cloudfront.net/wp-content/uploads/2008/04/wget.zip">Download wget for Mac OS X (124 KB)</a></p>
<h4>Install wget</h4>
<p><strong>For normal mac setups.</strong></p>

<div class="wp_syntax"><div class="code"><pre class="code" style="font-family:monospace;"># Open Terminal: Applications/Utilitys/Terminal
# This is assuming the wget folder is in Downloads
cd Downloads
cd wget
sudo mv wget /usr/local/bin
password:
sudo mv wget.1 /usr/local/man/man1
sudo mv wgetrc /usr/local/etc
&nbsp;
# Close then reopen your terminal
# Now lets test! Simply do:
wget
&nbsp;
 # Output
wget: missing URL
Usage: wget [OPTION]... [URL]...
&nbsp;
Try `wget --help' for more options.</pre></div></div>

<p>This will work 99% of the time, but i have seen one case that this did not work. When calling &#8220;sudo mv wget.1 /usr/local/man/man1&#8243; and it responds &#8220;No such file or directory&#8221; do not freak out! I have the solution for you, below is for users that received an error after trying to move the wget.1 to man1 folder.</p>
<h4>Install wget (option 2)</h4>
<p><strong>For other mac setups.</strong></p>

<div class="wp_syntax"><div class="code"><pre class="code" style="font-family:monospace;"># ONLY IF YOU GOT AN ERROR &quot;No such file or directory: MAN1&quot;
# DO NOT USE THIS IF THE CODE ABOVE WORKED AND YOU CAN USE WGET
# May need to re-download
sudo mv wget /usr/bin
password:
sudo mv wget.1 /usr/share/man/man1
sudo mv wgetrc /usr/local/etc
&nbsp;
# Close then reopen your terminal
# Now lets test! Simply do:
wget
&nbsp;
# Output
wget: missing URL
Usage: wget [OPTION]... [URL]...
&nbsp;
Try `wget --help' for more options.</pre></div></div>

<p>So now thats installed, what do we use it for? Well are you wanting to download my lasted version of the Winn Guestbook? You can easily download it with wget now! Let me show you how!</p>

<div class="wp_syntax"><div class="code"><pre class="code" style="font-family:monospace;"># Download the latest version of the Winn Grestbook (v2.2.9)
# First 'cd' to the directory you want it to download too.
wget http://winn.ws/downloads/guestbook_v2-2-9.zip
&nbsp;
# done!</pre></div></div>

<p>Works great! Leran more about using wget and other commands with this book from amazon.com: <a href="http://www.amazon.com/gp/product/0470478365?ie=UTF8&#038;tag=winnws-20&#038;linkCode=as2&#038;camp=1789&#038;creative=390957&#038;creativeASIN=0470478365">MAC OS X UNIX Toolbox: 1000+ Commands for the Mac OS X</a><img src="http://www.assoc-amazon.com/e/ir?t=winnws-20&#038;l=as2&#038;o=1&#038;a=0470478365" width="1" height="1" border="0" alt="" style="border:none !important; margin:0px !important;" /></p>
]]></content:encoded>
			<wfw:commentRss>http://winn.ws/archives/139/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

<!-- Performance optimized by W3 Total Cache. Learn more: http://www.w3-edge.com/wordpress-plugins/

Minified using disk: basic
Database Caching 2/31 queries in 0.058 seconds using disk: basic
Object Caching 475/540 objects using disk: basic
Content Delivery Network via Amazon Web Services: CloudFront: d45jz936mo8n8.cloudfront.net

Served from: winn.ws @ 2012-02-07 19:57:06 -->
