<?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>botsko &#187; Mac</title>
	<atom:link href="http://www.botsko.net/blog/category/mac/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.botsko.net/blog</link>
	<description>continuing education</description>
	<lastBuildDate>Sat, 24 Jul 2010 21:42:29 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0</generator>
		<item>
		<title>Git Status in Command Line</title>
		<link>http://www.botsko.net/blog/2010/03/16/git-status-in-command-line/</link>
		<comments>http://www.botsko.net/blog/2010/03/16/git-status-in-command-line/#comments</comments>
		<pubDate>Tue, 16 Mar 2010 21:43:34 +0000</pubDate>
		<dc:creator>Michael Botsko</dc:creator>
				<category><![CDATA[Git]]></category>
		<category><![CDATA[Mac]]></category>

		<guid isPermaLink="false">http://www.botsko.net/blog/?p=545</guid>
		<description><![CDATA[There are many tricks out there to get the git status to show in the command line path, but here&#8217;s one that worked the best for me on a Mac OS X Snow Leopard machine. Download the git tarball, and find the contrib/completion/git-completion.bash file. Move it to a good location on your system. In my [...]]]></description>
			<content:encoded><![CDATA[<p>There are many tricks out there to get the git status to show in the command line path, but here&#8217;s one that worked the best for me on a Mac OS X Snow Leopard machine.<br />
<span id="more-545"></span><br />
Download the git tarball, and find the contrib/completion/git-completion.bash file. Move it to a good location on your system. In my situation I went with:</p>
<p><code>/opt/local/etc/bash_completion.d/git-completion</code></p>
<p>Import that code into your .bash_profile and then add in the code necessary to append the branch name output:</p>
<p><code>. /opt/local/etc/bash_completion.d/git-completion<br />
PS1='\h:\W$(__git_ps1 "(%s)") \u\$ '</code></p>
<p>You&#8217;re done. If you&#8217;re getting the &#8220;command not found&#8221; error after restarting the terminal, be sure your completion file is in the right spot.</p>
<p>If you want to color things a bit, you could change it to one of the options below:</p>
<p><code>RED="\[\033[0;31m\]"<br />
GREEN="\[\033[0;32m\]"<br />
YELLOW="\[\033[0;33m\]"<br />
BLUE="\[\033[0;34m\]"<br />
PURPLE="\[\033[0;35m\]"<br />
TEAL="\[\033[0;36m\]"<br />
GRAY="\[\033[0;37m\]"<br />
WHITE="\[\033[0;38m\]"<br />
PS1="$TEAL\h: $GRAY\W$GREEN \$(__git_ps1 '(%s)')$WHITE \$ "<br />
</code></p>
<p>A ton of different ways can be found here:<br />
<a href="http://asemanfar.com/Current-Git-Branch-in-Bash-Prompt">http://asemanfar.com/Current-Git-Branch-in-Bash-Prompt</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.botsko.net/blog/2010/03/16/git-status-in-command-line/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Installing Git on Mac OS X Snow Leapord</title>
		<link>http://www.botsko.net/blog/2010/02/18/installing-git-on-mac-os-x-snow-leapord/</link>
		<comments>http://www.botsko.net/blog/2010/02/18/installing-git-on-mac-os-x-snow-leapord/#comments</comments>
		<pubDate>Thu, 18 Feb 2010 16:37:21 +0000</pubDate>
		<dc:creator>Michael Botsko</dc:creator>
				<category><![CDATA[Git]]></category>
		<category><![CDATA[Mac]]></category>

		<guid isPermaLink="false">http://www.botsko.net/blog/?p=520</guid>
		<description><![CDATA[Git is an amazing source control system, and is even better when used with GitHub.com. Installing git on Mac is pretty simple. First, download the latest version from git-scm.com. Extract the contents of the archive and open terminal to the new folder. Note: Since this requires compiling, you must have the developer tools installed. Download [...]]]></description>
			<content:encoded><![CDATA[<p>Git is an amazing source control system, and is even better when used with <a href="http://www.github.com">GitHub.com</a>. Installing git on Mac is pretty simple.<br />
<span id="more-520"></span><br />
First, download the latest version from <a href="http://www.git-scm.com">git-scm.com</a>. Extract the contents of the archive and open terminal to the new folder.</p>
<p>Note: Since this requires compiling, you must have the developer tools installed. Download and install the <a href="http://developer.apple.com/tools/xcode/">Xcode</a> package from Apple.</p>
<p><code>$ ./configure --prefix=/opt/git<br />
$ make<br />
$ sudo make install</code></p>
<p>Now that it&#8217;s installed, you need to make sure it&#8217;s in your path. Add the following content your bash profile:</p>
<p><code>$ vi ~/.bash_profile</code><br />
<code>export PATH=${PATH}:/opt/git/bin</code></p>
<p>Restart terminal and you should see the manual for git when you run the <code>git</code> command.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.botsko.net/blog/2010/02/18/installing-git-on-mac-os-x-snow-leapord/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Magic Mouse</title>
		<link>http://www.botsko.net/blog/2010/01/18/magic-mouse/</link>
		<comments>http://www.botsko.net/blog/2010/01/18/magic-mouse/#comments</comments>
		<pubDate>Mon, 18 Jan 2010 23:17:50 +0000</pubDate>
		<dc:creator>Michael Botsko</dc:creator>
				<category><![CDATA[Mac]]></category>

		<guid isPermaLink="false">http://www.botsko.net/blog/?p=513</guid>
		<description><![CDATA[I was planning on getting a magic mouse for my office machine sometime in 2010, but my parents got one for me for the holidays. It finally arrived and I&#8217;ve had some time to play with it. Here are some briefs thoughts and comments. As always the &#8220;unboxing&#8221; was exciting and the packaging was very [...]]]></description>
			<content:encoded><![CDATA[<p>I was planning on getting a magic mouse for my office machine sometime in 2010, but my parents got one for me for the holidays. It finally arrived and I&#8217;ve had some time to play with it. Here are some briefs thoughts and comments.<br />
<span id="more-513"></span><br />
As always the &#8220;unboxing&#8221; was exciting and the packaging was very clean and used minimal trash. Setting up the mouse was extremely easy. The mouse takes two AA batteries so it&#8217;s a bit heavier than my previous mouse, and the lower height is going to be a bit of an adjustment for me, but it&#8217;s understandable considering the nature of needing to have a more level surface.</p>
<p>The clicking and scrolling work just as I expected and after re-watching the video the two-finger-swipe worked as well. Using it as a web browser back/forward button is going to be very useful.</p>
<p>I installed the MagicPrefs tool and immediately added some functionality &#8211; tapping the apple logo stem now shows me the spaces menu, and a three-finger click now reveals the desktop. </p>
<p>After using it for a good week I still enjoy it, but I have a better idea of where it&#8217;s weaker. I had to deactivate a custom three-finger trigger because it kept activating when it wasn&#8217;t intended. I assume it was simply the way I click or rest my hand. </p>
<p>Pros:</p>
<ul>
<li>Flawless 360 degree scrolling, no ball/dirt to get in the way.</li>
<li>Very smooth and easy to keep clean.</li>
<li>Wireless connection works well.</li>
<li>Two-finger swipe motion works well, when I use it.</li>
</ul>
<p>Cons:</p>
<ul>
<li>Too sensitive when you rest part of your hand on it. I&#8217;ve accidentally scrolled away when I didn&#8217;t intend to.</li>
<li>No left/middle/right tactile feedback. I constantly do a &#8220;middle click&#8221; rather than a &#8220;left click&#8221; because I was unaware that the mouse shifted position in my hand.</li>
<li>Two-finger swipe is hard to adjust to while keeping your hand still.</li>
</ul>
<p>I&#8217;m still learning to adjust so I&#8217;m sure things will become easier over time. I used to complain about some caps lock difficulty when I first switched from PC but that&#8217;s completely disappeared. Over all I enjoy it &#8211; a mouse that has the scrolling I really want without the moving parts that are too sensitive to dirt. </p>
]]></content:encoded>
			<wfw:commentRss>http://www.botsko.net/blog/2010/01/18/magic-mouse/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Missing mysql.sock on Mac OS X</title>
		<link>http://www.botsko.net/blog/2009/03/16/missing-mysqlsock-on-mac-os-x/</link>
		<comments>http://www.botsko.net/blog/2009/03/16/missing-mysqlsock-on-mac-os-x/#comments</comments>
		<pubDate>Mon, 16 Mar 2009 17:39:48 +0000</pubDate>
		<dc:creator>Michael Botsko</dc:creator>
				<category><![CDATA[Mac]]></category>
		<category><![CDATA[MySQL]]></category>

		<guid isPermaLink="false">http://www.botsko.net/blog/?p=282</guid>
		<description><![CDATA[Recently I was doing some local development on my Mac OS X Leopard machine. When running apache2 with php I was able to connect to the database just fine, and from the command line I was able to run mysql commands. However, when running a php script from the command line I was getting an [...]]]></description>
			<content:encoded><![CDATA[<p>Recently I was doing some local development on my Mac OS X Leopard machine. When running apache2 with php I was able to connect to the database just fine, and from the command line I was able to run mysql commands.</p>
<p>However, when running a php script from the command line I was getting an error:</p>
<p><code>Warning: mysql_connect(): Can't connect to local MySQL server through socket '/var/mysql/mysql.sock' (2)</code></p>
<p>After spending some time thinking it was the code, I discovered that the mysql.sock file was missing.</p>
<p>Others on the net found the file elsewhere, like <code>/private/tmp/mysql.sock</code> or <code>/tmp/mysql.sock</code> but I had absolutely no .sock file anywhere. </p>
<p>Turns out, it did exist, but was named differently. According to the php.ini, the file was located at</p>
<p><code>/usr/local/mysql/run/mysql_socket </code></p>
<p>So, the solution was to create a symlink in /var/mysql to the proper file.</p>
<p><code>sudo ln -s /usr/local/mysql/run/mysql_socket /var/mysql/mysql.sock</code></p>
]]></content:encoded>
			<wfw:commentRss>http://www.botsko.net/blog/2009/03/16/missing-mysqlsock-on-mac-os-x/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>New System: iMac 20&#8243; 2.4Ghz</title>
		<link>http://www.botsko.net/blog/2007/11/19/new-system-imac-20-24ghz/</link>
		<comments>http://www.botsko.net/blog/2007/11/19/new-system-imac-20-24ghz/#comments</comments>
		<pubDate>Mon, 19 Nov 2007 23:58:16 +0000</pubDate>
		<dc:creator>Michael Botsko</dc:creator>
				<category><![CDATA[Mac]]></category>
		<category><![CDATA[Systems]]></category>

		<guid isPermaLink="false">http://www.botsko.net/blog/2007/11/19/new-system-imac-20-24ghz/</guid>
		<description><![CDATA[A few weeks back my old primary system suffered some serious boot issues and was out for an entire day. After a lot of time wasted trying to save things with knoppix, etc, I finally went out and bought a new system. I&#8217;ve grown used to developing on windows so things have been a little [...]]]></description>
			<content:encoded><![CDATA[<p>A few weeks back my old primary system suffered some serious boot issues and was out for an entire day. After a lot of time wasted trying to save things with knoppix, etc, I finally went out and bought a new system.</p>
<p>I&#8217;ve grown used to developing on windows so things have been a little slow, but I&#8217;m gradually adjusting to using a mac. I&#8217;ve already moved my dev server and my subversion server to this machine so I&#8217;ve brought the old system home for triage. Eventually, it will allow me work from home whenever I need to, and it allows us to play games again.</p>
<p>Two of our other systems are now up for sale on craigslist/ebay.</p>
<p>So far though, I&#8217;m doing just fine and am enjoying the new system. It&#8217;s much cleaner, more intuitive, etc.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.botsko.net/blog/2007/11/19/new-system-imac-20-24ghz/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Install Apache, MySQL, and PHP on OS X (10.5)</title>
		<link>http://www.botsko.net/blog/2007/11/19/install-apache-mysql-and-php-on-os-x-105/</link>
		<comments>http://www.botsko.net/blog/2007/11/19/install-apache-mysql-and-php-on-os-x-105/#comments</comments>
		<pubDate>Mon, 19 Nov 2007 23:53:09 +0000</pubDate>
		<dc:creator>Michael Botsko</dc:creator>
				<category><![CDATA[Apache]]></category>
		<category><![CDATA[Mac]]></category>
		<category><![CDATA[MySQL]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[Tech-Tidbit]]></category>

		<guid isPermaLink="false">http://www.botsko.net/blog/2007/11/19/install-apache-mysql-and-php-on-os-x-105/</guid>
		<description><![CDATA[While I was at zendcon I needed to setup my macbook with a typical apache/php/mysql server, but I was unsatisfied with both the default server that apple included and with the install system provided by XAMPP. I&#8217;ve since setup a server on both my MacBook and my iMac. In order to get support for mysql [...]]]></description>
			<content:encoded><![CDATA[<p>While I was at zendcon I needed to setup my macbook with a typical apache/php/mysql server, but I was unsatisfied with both the default server that apple included and with the install system provided by XAMPP. I&#8217;ve since setup a server on both my MacBook and my iMac.</p>
<p>In order to get support for mysql as well as tools necessary for compiling, you need to install the <a href="http://developer.apple.com/tools/download/">apple developer tools</a>. Check your original mac disc as you may already have a copy.</p>
<p>Anyway, on with our install:</p>
<p><strong>Apache</strong></p>
<p>First, download the latest version of the <a href="http://httpd.apache.org/download.cgi">apache httpd web server</a>.</p>
<p><code>./configure --prefix=/usr/local/apache --enable-module=so --enable-module=rewrite</code></p>
<p>Then, run the standard <code>make, sudo make install.</code></p>
<p><strong>MySQL</strong></p>
<p>Then download the <a href="http://dev.mysql.com/downloads/mysql/5.0.html#source">latest mysql source file</a>. Make sure you download the source &#8220;Compressed GNU TAR archive (tar.gz)&#8221; as we&#8217;ll need to custom compile it.</p>
<p>However, PHP5 no longer includes mysql shared libraries needed during the configure process. To get these, download the source file for the mysql version you just installed. Once downloaded, decompress it and run the following:</p>
<p><code>./configure --prefix=/usr/local/mysql --with-unix-socket-path=/usr/local/mysql/run/mysql_socket  --with-mysqld-user=mysql --with-comment --with-debug</code></p>
<p><code>make</code></p>
<p><code>sudo make install</code></p>
<p><code>sudo /usr/local/mysql/bin/mysql_install_db --force</code></p>
<p><code>sudo mkdir /usr/local/mysql/run</code><br />
<code>sudo mkdir /usr/local/mysql/data</code></p>
<p><code>sudo chgrp -R mysql /usr/local/mysql</code></p>
<p><code>sudo chown -R mysql /usr/local/mysql/run /usr/local/mysql/var /usr/local/mysql/data</code></p>
<p>Then start the server with:</p>
<p><code>sudo /usr/local/mysql/bin/mysqld_safe --user=mysql &#038;</code></p>
<p><strong>zlib</strong></p>
<p>Then, <a href="http://www.zlib.net/">install zlib</a> if it&#8217;s not already installed on your system. Download zlib, and it should be a basic <code>./configure, make, sudo make install</code> process. </p>
<p>Once zlib is installed, make sure you know the path as we&#8217;ll need it during the php configure process.</p>
<p><strong>PHP</strong></p>
<p>Next, download the <a href="http://www.php.net/downloads.php">latest php package</a>. Decompress it, and now we&#8217;re ready to configure.</p>
<p><code>./configure --prefix=/usr/local/apache --enable-cli --with-mysql=/usr/local/mysql --with-zlib-dir=/usr/local --with-apxs2=/usr/local/apache/bin/apxs</code></p>
<p>Then, run <code>make</code> and<code> sudo make install</code> to complete the process.</p>
<p>Restart apache and test everything out. If php didn&#8217;t do it automatically, add in <code>AddType application/x-httpd-php .php</code> to your httpd.conf file &#8211; commonly located in <code>/usr/local/apache/conf/httpd.conf</code>.</p>
<p>Then, start your webserver.</p>
<p><code>sudo /usr/local/apache/bin/apachectl start</code></p>
<p>And finally, once everything is done you&#8217;ll want to setup your account to properly allow access to mysql and apache commands. Just run the following to add their paths to your bash profile:</p>
<p><code>echo 'export PATH=/usr/local/mysql/bin:$PATH' >> ~/.bash_profile<br />
echo 'export PATH=/usr/local/apache/bin:$PATH' >> ~/.bash_profile</code></p>
]]></content:encoded>
			<wfw:commentRss>http://www.botsko.net/blog/2007/11/19/install-apache-mysql-and-php-on-os-x-105/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Moving Subversion Repository Across Machines</title>
		<link>http://www.botsko.net/blog/2007/11/14/moving-subversion-repository-across-machines/</link>
		<comments>http://www.botsko.net/blog/2007/11/14/moving-subversion-repository-across-machines/#comments</comments>
		<pubDate>Wed, 14 Nov 2007 18:31:55 +0000</pubDate>
		<dc:creator>Michael Botsko</dc:creator>
				<category><![CDATA[Mac]]></category>
		<category><![CDATA[Subversion/CVS]]></category>
		<category><![CDATA[Tech-Tidbit]]></category>

		<guid isPermaLink="false">http://www.botsko.net/blog/2007/11/14/moving-subversion-repository-across-machines/</guid>
		<description><![CDATA[I recently moved my development server from a linux box to my primary machine, an iMac. I wanted to move my subversion repository while maintaining the file histories for everything inside. Worrying that it was going to be a huge issue, I was happy to discover it was completely simple: On the existing repository machine, [...]]]></description>
			<content:encoded><![CDATA[<p>I recently moved my development server from a linux box to my primary machine, an iMac. I wanted to move my subversion repository while maintaining the file histories for everything inside. Worrying that it was going to be a huge issue, I was happy to discover it was completely simple:</p>
<p>On the existing repository machine, run:</p>
<p><code>svnadmin dump /path/to/repository > repository-name.dmp</code></p>
<p>Transfer your dump file to the new machine and then, create a repository. Once subversion is running and you have your repository created, import the dump file:</p>
<p><code>svnadmin load /path/to/repository-name< /path/to/repository-name.dmp</code></p>
<p>You're done!</code></p>
]]></content:encoded>
			<wfw:commentRss>http://www.botsko.net/blog/2007/11/14/moving-subversion-repository-across-machines/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Setting up Subversion on Mac OS X 10.5</title>
		<link>http://www.botsko.net/blog/2007/11/14/setting-up-subversion-on-mac-os-x-105/</link>
		<comments>http://www.botsko.net/blog/2007/11/14/setting-up-subversion-on-mac-os-x-105/#comments</comments>
		<pubDate>Wed, 14 Nov 2007 18:26:51 +0000</pubDate>
		<dc:creator>Michael Botsko</dc:creator>
				<category><![CDATA[Mac]]></category>
		<category><![CDATA[Subversion/CVS]]></category>
		<category><![CDATA[Tech-Tidbit]]></category>

		<guid isPermaLink="false">http://www.botsko.net/blog/2007/11/14/setting-up-subversion-on-mac-os-x-105/</guid>
		<description><![CDATA[I recently began working exclusively on an iMac so I decided to setup a subversion server locally and as my new machine would simply replace my local development machine, which is a Fedora Core 6 pc. You&#8217;ll need to setup at least one repository. I&#8217;m going to need multiple repositories that I can use for [...]]]></description>
			<content:encoded><![CDATA[<p>I recently began working exclusively on an iMac so I decided to setup a subversion server locally and as my new machine would simply replace my local development machine, which is a Fedora Core 6 pc.</p>
<p>You&#8217;ll need to setup at least one repository. I&#8217;m going to need multiple repositories that I can use for different clients so I have a bit of extra admin work ahead of me. You can setup as many repositories as you need, but no matter what you&#8217;ll need at least one. Here create the folders&#8230;</p>
<p><code># mkdir /svn<br />
# mkdir /svn/repos</code></p>
<p>Then we need to tell subversion to make our first repository.<br />
<code><br />
# svnadmin create /svn/repos/myproject</code></p>
<p>First, I need to setup a config file for svnserve.</p>
<p><code># vi /svn/repos/conf/svnserve.conf</code></p>
<p>Then, look for variations of the following code and edit it as necessary. By default any anonymous user can access the code so to disable that you <strong>must</strong> include anon-access = none, just commenting the value out will not prevent anonymous access.</p>
<p><code>anon-access = none<br />
password-db = passwdfile<br />
realm = My SVN Repository<br />
auth-access = write</code></p>
<p>The password-db is just a path to a file containing usernames and passwords. You&#8217;ll create this file especially for SVN. I create each file inside of the repository conf directory. So, save your changes and then we&#8217;ll create said user file.</p>
<p><code># vi passwdfile</code></p>
<p>Enter in something like:</p>
<p><code>[users]<br />
username = password</code></p>
<p>Anyway, you&#8217;ll need to start the svn server.</p>
<p><code># svnserve -d --listen-port=3690</code></p>
<p><em>One side note &#8211; svnserve just runs and doesn&#8217;t have a way to stop besides killing the process. If you make changes to the svnserve.conf or user file you&#8217;ll need to restart svnserve.</em></p>
<p><code># killall svnserve</code></p>
<p>Then, go ahead and test (best to do so on a different machine).<br />
<code><br />
# svn co --username=myusername svn://mydomain/svn/repos/myproject<br />
</code></p>
<p>The system should then ask you for your password. Go ahead and run some tests. </p>
]]></content:encoded>
			<wfw:commentRss>http://www.botsko.net/blog/2007/11/14/setting-up-subversion-on-mac-os-x-105/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
