<?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>ELEVATION Dev Blog &#187; tools</title>
	<atom:link href="http://dev.elevationblog.com/category/tools/feed/" rel="self" type="application/rss+xml" />
	<link>http://dev.elevationblog.com</link>
	<description></description>
	<lastBuildDate>Wed, 06 Oct 2010 21:07:24 +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>refinerycms-blog: comments with DISQUS</title>
		<link>http://dev.elevationblog.com/2010/04/08/refinerycms-blog-comments-with-disqus/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=refinerycms-blog-comments-with-disqus</link>
		<comments>http://dev.elevationblog.com/2010/04/08/refinerycms-blog-comments-with-disqus/#comments</comments>
		<pubDate>Fri, 09 Apr 2010 00:19:25 +0000</pubDate>
		<dc:creator>Jared</dc:creator>
				<category><![CDATA[tips]]></category>
		<category><![CDATA[tools]]></category>

		<guid isPermaLink="false">http://dev.elevationblog.com/?p=1614</guid>
		<description><![CDATA[For adding a blog to your refinery site, there&#8217;s pretty much only one option: the refinerycms-blog plugin. Fortunately like most refinery things, it&#8217;s pretty easy to customize. I wanted to use DISQUS to moderate the comments on this particular blog, and here&#8217;s how I did it (You obviously need a DISQUS account to do this).  [...]]]></description>
			<content:encoded><![CDATA[<p>For adding a blog to your refinery site, there&#8217;s pretty much only one option: the <a href="http://github.com/unixcharles/refinerycms-blog" target="_blank">refinerycms-blog plugin</a>. Fortunately like most refinery things, it&#8217;s pretty easy to customize.</p>
<p>I wanted to use <a href="http://disqus.com">DISQUS</a> to moderate the comments on this particular blog, and here&#8217;s how I did it (You obviously need a DISQUS account to do this).  If a file referred to doesn&#8217;t exist, copy it from vendor/plugins/app/views/blogs to your theme directory.</p>
<ol>
<li><strong>Remove the old comment form:<br />
themes/mysite/views/blogs/show.html.erb</strong><br />
remove the render &#8220;_form&#8221; line since we don&#8217;t need a comment form anymore</li>
<li><strong>Add the Disqus embed code<br />
themes/mytheme/views/blogs/_comments.html.erb</strong><br />
Replace everything in this file with the disqus embed code, replace mysite below with your disqus shortname.</p>
<pre class="brush: plain">&lt;div id='comments'&gt;
 &lt;div id="disqus_thread"&gt;&lt;/div&gt;
 &lt;script type="text/javascript"&gt;
 var disqus_identifier = "&lt;%= @blog.permalink %&gt;";
 &lt;%= "var disqus_developer = 1;" if local_request? %&gt;

 (function() {
 var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true;
 dsq.src = 'http://mysite.disqus.com/embed.js';
 (document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq);
 })();
 &lt;/script&gt;
 &lt;noscript&gt;Please enable JavaScript to view the &lt;a href="http://disqus.com/?ref_noscript=mysite"&gt;comments powered by Disqus.&lt;/a&gt;&lt;/noscript&gt;
&lt;/div&gt;</pre>
</li>
<li><strong>Add the disqus comment counter code<br />
/themes/mysite/views/blogs/index.html.erb<br />
</strong><br />
Change line 16 to:</p>
<pre class="brush: plain">
  <%= link_to 'Read more', blog_post_url(blog.permalink)+"#disqus_thread" -%>
</pre>
<p>Put this somewhere near the bottom:</p>
<pre class="brush: plain">&lt;% content_for :footer do -%&gt;
 &lt;script type="text/javascript"&gt;
 //&lt;![CDATA[
 (function() {
 var links = document.getElementsByTagName('a');
 var query = '?';
 for(var i = 0; i &lt; links.length; i++) {
 if(links[i].href.indexOf('#disqus_thread') &gt;= 0) {
 query += 'url' + i + '=' + encodeURIComponent(links[i].href) + '&amp;';
 }
 }
 document.write('&lt;script charset="utf-8" type="text/javascript" src="http://disqus.com/forums/poetrybooths/get_num_replies.js' + query + '"&gt;&lt;/' + 'script&gt;');
 })();
 //]]&gt;
 &lt;/script&gt;
&lt;% end -%&gt;</pre>
<p><strong>/themes/mysite/views/shared/_footer.html.erb<br />
</strong>add &lt;%= yield :footer %&gt; to your footer file so our comment counter javascript gets placed there.</li>
</ol>
<p>Pretty easy.</p>
]]></content:encoded>
			<wfw:commentRss>http://dev.elevationblog.com/2010/04/08/refinerycms-blog-comments-with-disqus/feed/</wfw:commentRss>
		<slash:comments>27</slash:comments>
		</item>
		<item>
		<title>refinerycms _blank target nav</title>
		<link>http://dev.elevationblog.com/2010/04/07/refinerycms-_blank-target-nav/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=refinerycms-_blank-target-nav</link>
		<comments>http://dev.elevationblog.com/2010/04/07/refinerycms-_blank-target-nav/#comments</comments>
		<pubDate>Wed, 07 Apr 2010 19:23:37 +0000</pubDate>
		<dc:creator>Jared</dc:creator>
				<category><![CDATA[tips]]></category>
		<category><![CDATA[tools]]></category>
		<category><![CDATA[cms]]></category>
		<category><![CDATA[refinery]]></category>
		<category><![CDATA[refinerycms]]></category>

		<guid isPermaLink="false">http://dev.elevationblog.com/?p=1609</guid>
		<description><![CDATA[Recently I&#8217;ve been evaluating refinerycms for a few client projects that it seemed suited for, and I really like that while it&#8217;s not always 100% what I want, it&#8217;s very easy to modify to get it to where I need it. Here&#8217;s an example: My site needs a main nav to link offsite in a [...]]]></description>
			<content:encoded><![CDATA[<p>Recently I&#8217;ve been evaluating <a href="http://refinerycms.com">refinerycms</a> for a few client projects that it seemed suited for, and I really like that while it&#8217;s not always 100% what I want, it&#8217;s very easy to modify to get it to where I need it.</p>
<p>Here&#8217;s an example: My site needs a main nav to link offsite in a new window by adding target=&#8221;_blank&#8221; to the link, which is not handled out of the box by refinery.  So I copied vendor/refinery/app/views/shared/_menu_branch.html.erb into my theme directory to override the functionality and modified line 11 to the following:</p>
<pre>&lt;%= link_to menu_branch.title, menu_branch.url, \
:target =&gt; menu_branch.url.include?("http://") ? "_blank" : "" %&gt;
</pre>
<p>Now any link containing http:// is automatically given a blank target. Presto.</p>
]]></content:encoded>
			<wfw:commentRss>http://dev.elevationblog.com/2010/04/07/refinerycms-_blank-target-nav/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>getting git</title>
		<link>http://dev.elevationblog.com/2008/10/15/getting-git/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=getting-git</link>
		<comments>http://dev.elevationblog.com/2008/10/15/getting-git/#comments</comments>
		<pubDate>Wed, 15 Oct 2008 05:31:00 +0000</pubDate>
		<dc:creator>Jared</dc:creator>
				<category><![CDATA[Home]]></category>
		<category><![CDATA[ideology]]></category>
		<category><![CDATA[tools]]></category>
		<category><![CDATA[git]]></category>
		<category><![CDATA[svn]]></category>
		<category><![CDATA[textmate]]></category>
		<category><![CDATA[workflow]]></category>

		<guid isPermaLink="false">http://elevationblog.com/2008/10/15/getting-git</guid>
		<description><![CDATA[I&#8217;ve been hesitant to explore git since subversion was (I thought) really handling all my needs just fine. Why waste time learning another version control workflow? Over time, I started to realize there were things about git that would be really nice, like nice branching and merging in particular, but I thought, that&#8217;s for some [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve been hesitant to explore <a href="http://git.or.cz/">git</a> since <a href="http://subversion.tigris.org/">subversion</a> was (I thought) really handling all my needs just fine.  Why waste time learning another version control workflow?</p>
<p>Over time, I started to realize there were things about git that would be really nice, like nice branching and merging in particular, but I thought, that&#8217;s for some day when I have time to learn it, or my pain becomes too great with branches (which I don&#8217;t use that often in svn).</p>
<p>Just a couple days ago I needed to extend some code that was hosted on github, so I forked it, cloned it, and just started to work.  In that process I&#8217;m discovering things that are just making git start to click.  Whoops, didn&#8217;t mean to commit that yet: git-reset.  I need to pull in some other changes, but can&#8217;t yet because I have uncommitted changes: git-stash.</p>
<p>Combined with the <a href="http://gitorious.org/projects/git-tmbundle">git bundle for textmate</a>, I&#8217;m actually having fun learning git.</p>
<p>Moral: Try new stuff (in a real-life scenario), it&#8217;s fun and can make your life better.</p>
]]></content:encoded>
			<wfw:commentRss>http://dev.elevationblog.com/2008/10/15/getting-git/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

