<?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> &#187; guide</title>
	<atom:link href="http://blog.kfirbreger.com/tag/guide/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.kfirbreger.com</link>
	<description></description>
	<lastBuildDate>Tue, 24 Jan 2012 09:47:15 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>Installing PostgreSQL and Sql-Ledger for Django apps on Snow Leopard</title>
		<link>http://blog.kfirbreger.com/2010/10/15/installing-postgresql-and-sql-ledger-for-django-apps-on-snow-leopard/</link>
		<comments>http://blog.kfirbreger.com/2010/10/15/installing-postgresql-and-sql-ledger-for-django-apps-on-snow-leopard/#comments</comments>
		<pubDate>Fri, 15 Oct 2010 19:03:09 +0000</pubDate>
		<dc:creator>Kfir</dc:creator>
				<category><![CDATA[guide]]></category>
		<category><![CDATA[work]]></category>
		<category><![CDATA[django]]></category>
		<category><![CDATA[it]]></category>
		<category><![CDATA[os x]]></category>
		<category><![CDATA[postgresql]]></category>
		<category><![CDATA[python]]></category>
		<category><![CDATA[sql-ledger]]></category>

		<guid isPermaLink="false">http://blog.kfirbreger.com/?p=279</guid>
		<description><![CDATA[At DOP we started working on a django front end for Sql-Ledger with the idea of combining it later on with our ticketing system. Getting it going on my MacBook proved to be more challenging then expected. Most of the problems were easily solvable, but finding the oplossing proved to be tricky. Therefor I have [...]]]></description>
			<content:encoded><![CDATA[<p>At DOP we started working on a django front end for Sql-Ledger with the idea of combining it later on with our ticketing system. Getting it going on my MacBook proved to be more challenging then expected. Most of the problems were easily solvable, but finding the oplossing proved to be tricky. Therefor I have decided to create this simple guide, showing the steps I have taken to get everything going.</p>
<p><strong>Step 1: PostgreSQL</strong></p>
<p>You can download a binary installer from the <a title="PostgreSQL download" href="http://www.postgresql.org/download/">PostgreSQL site</a>. It will install Postgre to your <code>/Library</code> folder. This should take care of the Postgre part.</p>
<p><strong>Step 2: Sql-Ledger</strong></p>
<p>Ledger is written in perl, and requires perl to run. Luckily Snow Leopard comes standard with perl. What it does not come standard with is the perl binding for PostgreSQL. The following 3 commands will take care of that:</p>
<p><code>sudo perl -MCPAN -e "install +YAML"</code><br />
YAML is not necessary but it can be helpful, and lacking YAML might give you problems with DBI.</p>
<p><code>sudo perl -MCPAN -e "install DBI"</code></p>
<p><code>sudo perl -MCPAN -e "install DBD::Pg"</code></p>
<p>This will install the perl binding for PostreSQL.</p>
<p>Download Sql-Ledger from <a href="http://www.sql-ledger.com/source/sql-ledger-2.8.31.tar.gz">here</a>. As of this writing, the latest version is 2.8.31</p>
<p>Unzip and untar the archive and follow the instructions in the readme file. I did not manage to build using the automated script and had to do everything by hand. There is also <a href="http://www.sql-ledger.org/cgi-bin/nav.pl?page=source/mac/howto-sql-ledger-osx.html">this page</a> on the ledger page with a somewhat oldish instructions for OS X.</p>
<p>Once Ledger is tested and it is working, its time to get the python binding</p>
<p><strong>Step 3: Python binding</strong></p>
<p><strong> </strong>The pyhton binding is for PostgreSQL. You can get the binding library, called Psycopg2 (don&#8217;t ask me why) from <a href="http://initd.org/psycopg/download/">here</a>. Download and upack it. Installing is done by running:<br />
<code>python setup.py build</code><br />
<code>sudo python setup.py install</code><br />
If you are not able to build it might be a problem with your path. Python is trying to link to the PostgreSQL bin files. Try to add it to your path and then to build again.</p>
<p>And your done. Enjoy (or not) working with Django-Sql-Ledger</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.kfirbreger.com/2010/10/15/installing-postgresql-and-sql-ledger-for-django-apps-on-snow-leopard/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Adding a movie with chapters from iMovie to iDVD</title>
		<link>http://blog.kfirbreger.com/2010/10/04/adding-a-movie-with-chapters-from-imovie-to-idvd/</link>
		<comments>http://blog.kfirbreger.com/2010/10/04/adding-a-movie-with-chapters-from-imovie-to-idvd/#comments</comments>
		<pubDate>Mon, 04 Oct 2010 20:43:32 +0000</pubDate>
		<dc:creator>Kfir</dc:creator>
				<category><![CDATA[guide]]></category>
		<category><![CDATA[idvd]]></category>
		<category><![CDATA[ilife]]></category>
		<category><![CDATA[imovie]]></category>
		<category><![CDATA[mac]]></category>
		<category><![CDATA[os x]]></category>

		<guid isPermaLink="false">http://blog.kfirbreger.com/?p=182</guid>
		<description><![CDATA[iLife 08 brought a big change to iMovie. iMovie 06 was a very capable video editing software with a good plugin library. iMovie 08 has taken a step back in the amount of pure editing feature. It seemed like apple was aiming to make iMovie the &#8220;iPhoto for home video&#8221;. One of the features not [...]]]></description>
			<content:encoded><![CDATA[<p>iLife 08 brought a big change to iMovie. iMovie 06 was a very capable video editing software with a good plugin library. iMovie 08 has taken a step back in the amount of pure editing feature. It seemed like apple was aiming to make iMovie the &#8220;iPhoto for home video&#8221;. One of the features not to make it to iMovie 08 was the ability to mark chapters for iDVD. In iLife 08 when you import a movie from iMovie to iDVD you get it as one movie. There is no way to break it down to chapters in iDVD as well. In comes GarageBand.</p>
<p>Made not only for music but also for creating podcasts, GarageBand can put markers on a track. iDVD will see these marks as well and treat them as chapters.  To mark chapters in a movie follow the following steps:</p>
<p>1. Start a new project in GarageBand and remove the default audio track.</p>
<p>2. in the media browser, select your iMovie movie that you want to add chapters to and drag it to GarageBand track window.</p>
<p>3. By pressing P, or choosing &#8212;- you can add a chapter marker at the player head location. I suggest you give the chapters more meaningful names then the default &#8220;Chapter&#8221; plus number that is automatically generated.</p>
<p>Once you have all the chapters marked there are two options to get this into iDVD. If this movie is the only movie you want to have chaptered in your DVD, you choose the export to iDVD option. If you choose this option a menu with the option to play the whole movie, or to choose between chapters will be created as well as chapter selection sub-menus.</p>
<p>Although this option is the simplest, you wont be able to combine two or more chaptered movies like this. To get around this you need to add one more step before going into iDVD. In GarageBand choose the &#8220;export to iTunes&#8221; option. This will add the movie to the the iTunes movie library.</p>
<p>Going now to iDVD, create a new project or open one you already have made. In the media browser go to iTunes section in the movie tab and drag the movie to the menu you want it on. iDVD will create the menus like it would if you would export from GarageBand. By creating a new menu page you can add another film. In this way you can have more then one chaptered  movie in iDVD.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.kfirbreger.com/2010/10/04/adding-a-movie-with-chapters-from-imovie-to-idvd/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>How to truly disable drupal cache</title>
		<link>http://blog.kfirbreger.com/2009/05/29/how-to-truly-disable-drupal-cache/</link>
		<comments>http://blog.kfirbreger.com/2009/05/29/how-to-truly-disable-drupal-cache/#comments</comments>
		<pubDate>Fri, 29 May 2009 10:26:05 +0000</pubDate>
		<dc:creator>Kfir</dc:creator>
				<category><![CDATA[guide]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[web]]></category>
		<category><![CDATA[drupal]]></category>
		<category><![CDATA[hacks]]></category>
		<category><![CDATA[php]]></category>

		<guid isPermaLink="false">http://blog.kfirbreger.com/?p=168</guid>
		<description><![CDATA[Drupal, like most CMSes uses cache intensively to speed things up. In a production site that is exactly what you what. However when developing, cache can cause you much pain. If your an expert in drupal you probably already realized when you need to clear the cache in order to see changes and when not [...]]]></description>
			<content:encoded><![CDATA[<div>
<p>
Drupal, like most CMSes uses cache intensively to speed things up. In a production site that is exactly what you what. However when developing, cache can cause you much pain.</p>
</div>
<div>
<p>
If your an expert in drupal you probably already realized when you need to clear the cache in order to see changes and when not too. the developer module even makes it quite easy to do. However for me, and I am quite sure to quite a lot of other people it is not that clear.
</p>
</div>
<div>
<p>&#8220;Wait&#8221;, you might say. &#8220;Drupal has a disable cache setting&#8221;. You would be right to say that. Only it doesn&#8217;t completely disable the cache, only part of the cache, namely the page caching. To truly disable cache you need to do a bit of a hacking to the cache code. Yes I know they say to never hack core (cache is part of the core drupal release). for me this was worth it. I figure as long as you remember its there and don&#8217;t use it in production you should be fine. The following piece of code needs to be added in <code>include/cache.inc</code>. There are two functions there that you need to edit:</p>
<ul>
<li><code>cache_get</code></li>
<li><code>cache_set</code></li>
</ul>
<p>In <code>cache_get</code> place the code right after the <code>global $user</code>. In <code>cache_set</code>  place it at the start of the function. Here is the code that you need to add.<br />
<code><br />
if(variable_get('cache', CACHE_DISABLED) == CACHE_DISABLED) {<br />
    return 0;<br />
}<br />
</code><br />
Kudos for this hack goes to Rolf van de Krol. Cheers mate.</p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://blog.kfirbreger.com/2009/05/29/how-to-truly-disable-drupal-cache/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>Installing Apache2, PHP5 and MySQL5 on OS X Tiger</title>
		<link>http://blog.kfirbreger.com/2009/05/04/installing-apache2-php5-and-mysql5-on-os-x-tiger/</link>
		<comments>http://blog.kfirbreger.com/2009/05/04/installing-apache2-php5-and-mysql5-on-os-x-tiger/#comments</comments>
		<pubDate>Mon, 04 May 2009 19:45:50 +0000</pubDate>
		<dc:creator>Kfir</dc:creator>
				<category><![CDATA[guide]]></category>
		<category><![CDATA[web]]></category>
		<category><![CDATA[apache]]></category>
		<category><![CDATA[install]]></category>
		<category><![CDATA[mysql]]></category>
		<category><![CDATA[os x]]></category>
		<category><![CDATA[php]]></category>

		<guid isPermaLink="false">http://blog.kfirbreger.com/?p=105</guid>
		<description><![CDATA[Tiger comes bundled with Apache 1.3 and PHP4. While these are still used for web development they are defenetly on the way out. For this reason I have decided to set up a more up to date MAMP installation on my old Powerbook G4. While this was all done on Tiger, it will most likely [...]]]></description>
			<content:encoded><![CDATA[<p>Tiger comes bundled with Apache 1.3 and PHP4. While these are still used for web development they are defenetly on the way out. For this reason I have decided to set up a more up to date MAMP installation on my old Powerbook G4. While this was all done on Tiger, it will most likely also work on Leopard.</p>
<h3><strong>Preparations</strong></h3>
<p>The installation process follows mostly the unix standard. That means that you will want to have the a /usr/local folder made. If you do not have it yet, type the following in terminal:</p>
<p><code>sudo mkdir /usr/local </code></p>
<p>The advantage of using local is that whenever a system updates itself it leaves local alone. If you install directly into /usr/bin, there is a chance that a system update will overwrite your installed software with its own update. If you lost me by now, you are probably off downloading a MAMP binary now.</p>
<p>The first step is to retrieve the packages we will need to properly install MAMP. To keep it nice and organized make a folder that will contain the source code, if you do not yet have a designated folder.</p>
<p><code>mkdir ~/src</code></p>
<p>We can now start installing MAMP</p>
<h3><strong>Installation</strong></h3>
<h4>MySQL</h4>
<p>The first thing that will be installed is MySQL. You can get the latest dmg <a href="http://dev.mysql.com/downloads/mysql/5.0.html#macosx-dmg" target="blank">here</a>. After installing MySQL from the dmg, I also recommend installing <a href="http://www.sequelpro.com" target="blank">Sequelpro</a> if you want a GUI interface to the database. For building MySQL yourself from source check <a href="http://hivelogic.com/articles/view/installing-mysql-on-mac-os-x" target="blank">this</a>.</p>
<h4>Apache2</h4>
<p>Apache comes bundled with OS X. Note that the control panel will only affect the default installation. Starting and stopping your own Apache installation will need some command line work, or some scripting. The following installs Apache 2 into  /usr/local/sbin/apache2, if you prefer to install into another folder change the prefix to that folder.<br />
<code><br />
curl -O http://apache.hippo.nl/httpd/httpd-2.2.11.tar.gz<br />
tar xvzf http-2.2.11.tar.gz<br />
cd http-2.2.11/<br />
./configure --prefix=/usr/local/sbin/apache2 --enable-modules=all --enable-mods-shared=all<br />
make<br />
sudo make install<br />
cd ..<br />
</code><br />
Before we continue to build PHP there are some extra libraries that are needed. If you are not interested in building PHP with GD you can probably skip most of them.</p>
<h4>Freetype</h4>
<p>A Free, High-Quality, and Portable Font Engine. You can learn more about it <a href="http://www.freetype.org">here</a>.<br />
<code><br />
curl -O http://mirrors.zerg.biz/nongnu/freetype/freetype-2.3.9.tar.gz<br />
tar xvzf freetype-2.3.9.tar.gz<br />
cd freetype-2.3.9/<br />
./configure<br />
make<br />
sudo make install<br />
cd ..<br />
</code></p>
<h4>JPEG</h4>
<p>Support for jpeg image format<br />
<code><br />
curl -O http://www.ijg.org/files/jpegsrc.v6b.tar.gz<br />
tar xzf jpegsrc.v6b.tar.gz<br />
cd jpeg-6b/<br />
cp /usr/share/libtool/config.sub .<br />
cp /usr/share/libtool/config.guess .<br />
./configure --enable-shared<br />
make<br />
sudo make install<br />
cd ..<br />
</code></p>
<h4>Libpng</h4>
<p>Support for png image format<br />
<code><br />
curl -O ftp://ftp.simplesystems.org/pub/libpng/png/src/libpng-1.2.36.tar.gz<br />
tar xjf libpng-1.2.36.tar.gz<br />
cd libpng-1.2.36/<br />
./configure<br />
make<br />
sudo make install<br />
cd ..<br />
</code></p>
<h4>openSSL</h4>
<p>Install the latest version of openSSL<br />
<code><br />
curl -O http://www.openssl.org/source/openssl-0.9.8k.tar.gz<br />
tar xvzf openssl-0.9.8k.tar.gz<br />
cd openssl-0.9.8k<br />
./config --prefix=/usr/local --openssldir=/usr/local/ssl<br />
make<br />
sudo make install<br />
./config shared --prefix=/usr/local --openssldir=/usr/local/ssl<br />
make clean<br />
make<br />
sudo make install<br />
</code></p>
<h4>PHP</h4>
<p>Now that the extra libraries are available we can continue to build PHP. We choose to install it into <code>/usr/local/php5</code>. As before if you wish to install into a different location, change the prefix.<br />
<code><br />
curl -O http://de3.php.net/distributions/php-5.2.9.tar.bz2<br />
tar xjf php-5.2.9.tar.bz2<br />
cd php-5.2.9/<br />
./configure --prefix=/usr/local/php5 --with-apxs2=/usr/local/sbin/apache2/bin/apxs --with-config-file-scan-dir=/usr/local/php5/php.d --with-iconv --with-openssl=/usr/local --with-openssl-dir=/usr/local/ssl --with-zlib=/usr --with-gd --with-zlib-dir=/usr --with-xmlrpc --with-iconv-dir=/usr --enable-exif --enable-sqlite-utf8 --enable-ftp --enable-sockets --enable-dbase --enable-mbstring --with-bz2=/usr --enable-fastcgi --enable-cgi --enable-zip --with-curl --with-mysql=/usr/local/mysql --with-pdo-mysql=/usr/local/mysql --with-libxml-dir=shared,/usr/local/php5 --with-jpeg-dir=/usr/local/php5 --with-png-dir=/usr/local/php5 --with-freetype-dir=/usr/local/php5<br />
make<br />
sudo make install<br />
</code><br />
You should now have a ready development system.</p>
<h3>Finalization</h3>
<p>To make sure that the newly installed software is used instead of the default installed one make sure that <code>/usr/local</code> and the bin and php5 folders within are in the path before <code>/usr/bin</code>.<br />
To start the Apache server use the following command:<br />
<code><br />
sudo /usr/local/sbin/apache2/bin/apachectl start<br />
</code><br />
Use <code>stop</code> and <code>restart</code> to stop or restart the server.</p>
<h4>Credit</h4>
<p>This article is inspired by the following three great guides:<br />
<a href="http://projects.serenity.de/php/">Compiling Apache and PHP (and MySQL) on Mac OS X Leopard</a><br />
<a href="http://www.bioneural.net/2005/04/22/apache-2-php-5-mysql-4-under-mac-os-x-1039/">Apache 2 + PHP 5 + MySQL 4 under OS X 10.3.9</a><br />
<a href="http://www.klauskomenda.com/archives/2008/10/07/installing-apache-mysql-and-php-on-leopard/">Installing Apache, MySQL and PHP on Leopard</a></p>
]]></content:encoded>
			<wfw:commentRss>http://blog.kfirbreger.com/2009/05/04/installing-apache2-php5-and-mysql5-on-os-x-tiger/feed/</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
	</channel>
</rss>

