<?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>SmartLogic Solutions Blog &#187; git</title>
	<atom:link href="http://blog.smartlogicsolutions.com/tag/git/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.smartlogicsolutions.com</link>
	<description>News and updates from the people at SmartLogic Solutions</description>
	<lastBuildDate>Tue, 30 Nov 2010 21:39:14 +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>Getting git-svn to run on OS X</title>
		<link>http://blog.smartlogicsolutions.com/2008/12/10/getting-git-svn-to-run-on-os-x/</link>
		<comments>http://blog.smartlogicsolutions.com/2008/12/10/getting-git-svn-to-run-on-os-x/#comments</comments>
		<pubDate>Thu, 11 Dec 2008 01:37:20 +0000</pubDate>
		<dc:creator>Greg Jastrab</dc:creator>
				<category><![CDATA[Greg Jastrab]]></category>
		<category><![CDATA[Subversion]]></category>
		<category><![CDATA[git]]></category>
		<category><![CDATA[mac]]></category>
		<category><![CDATA[os x]]></category>
		<category><![CDATA[perl]]></category>

		<guid isPermaLink="false">http://blog.smartlogicsolutions.com/?p=428</guid>
		<description><![CDATA[I&#8217;ve been gitting into git (clever, I know) lately, so I was trying to migrate my git commits for a project back into an existing subversion repository &#8211; another post coming on that later. When trying to run git-svn to import my subversion repository into git I got the following error, followed by a Perl [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve been gitting into <a href="http://git.or.cz/">git</a> (clever, I know) lately, so I was trying to migrate my git commits for a project back into an existing subversion repository &#8211; another post coming on that later.</p>
<p>When trying to run <a href="http://www.kernel.org/pub/software/scm/git/docs/git-svn.html">git-svn</a> to import my subversion repository into git I got the following error, followed by a Perl stack trace:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">Can<span style="color: #ff0000;">'t locate Term/ReadKey.pm</span></pre></div></div>

<p>A couple of installs got this working, read on&#8230;</p>
<p><span id="more-428"></span></p>
<h4>Install Term::ReadKey</h4>
<p>To install <a href="http://search.cpan.org/dist/TermReadKey/ReadKey.pm">Term::ReadKey</a>, fire up a terminal and type (you may need to sudo):</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">$<span style="color: #000000; font-weight: bold;">&gt;</span> <span style="color: #c20cb9; font-weight: bold;">perl</span> <span style="color: #660033;">-MCPAN</span> <span style="color: #660033;">-e</span> shell
cpan<span style="color: #000000; font-weight: bold;">&gt;</span> <span style="color: #c20cb9; font-weight: bold;">install</span> Term::ReadKey</pre></div></div>

<p>After a bunch of output I got the error message:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">Writing Makefile <span style="color: #000000; font-weight: bold;">for</span> Term::ReadKey
    <span style="color: #660033;">--</span> NOT OK
Running <span style="color: #c20cb9; font-weight: bold;">make</span> <span style="color: #7a0874; font-weight: bold;">test</span>
  Can<span style="color: #ff0000;">'t test without successful make
Running make install
  make had returned bad status, install seems impossible</span></pre></div></div>

<p>I tried to see what was wrong with the Makefile by trying to run make in the TermKey folder:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">~<span style="color: #000000; font-weight: bold;">/</span>.cpan<span style="color: #000000; font-weight: bold;">/</span>build<span style="color: #000000; font-weight: bold;">/</span>TermReadKey-<span style="color: #000000;">2.30</span> $<span style="color: #000000; font-weight: bold;">&gt;</span> <span style="color: #c20cb9; font-weight: bold;">make</span>
-bash: <span style="color: #c20cb9; font-weight: bold;">make</span>: <span style="color: #7a0874; font-weight: bold;">command</span> not found</pre></div></div>

<p>Interesting, didn&#8217;t realize OS X came preinstalled with things like perl but not make.</p>
<h4>Getting make on OS X</h4>
<p>I&#8217;m sure there&#8217;s an easier way to just get make on OS X, but I&#8217;m still new to my mac, so I wanted to install something supported by Apple instead of getting into stuff like ports.  After searching around on the Developer center I found that <a href="http://developer.apple.com/tools/xcode/">XCode</a> includes make.</p>
<p>After signing up for a free developer account and installing XCode, I now had make.</p>
<h4>Installing Term::ReadKey &#8211; round 2</h4>
<p>Let&#8217;s try this again&#8230;</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">$<span style="color: #000000; font-weight: bold;">&gt;</span> <span style="color: #c20cb9; font-weight: bold;">perl</span> <span style="color: #660033;">-MCPAN</span> <span style="color: #660033;">-e</span> shell
cpan<span style="color: #000000; font-weight: bold;">&gt;</span> <span style="color: #c20cb9; font-weight: bold;">install</span> Term::ReadKey
&nbsp;
CPAN: Storable loaded ok
Going to <span style="color: #c20cb9; font-weight: bold;">read</span> <span style="color: #000000; font-weight: bold;">/</span>Users<span style="color: #000000; font-weight: bold;">/</span>greg<span style="color: #000000; font-weight: bold;">/</span>.cpan<span style="color: #000000; font-weight: bold;">/</span>Metadata
  Database was generated on Wed, <span style="color: #000000;">10</span> Dec <span style="color: #000000;">2008</span> <span style="color: #000000;">11</span>:<span style="color: #000000;">26</span>:<span style="color: #000000;">54</span> GMT
Term::ReadKey is up to date.</pre></div></div>

<p>Hurray!  Now git-svn is working on OS X.</p>
<p>Other relevant Mac/Git links:</p>
<ul>
<li><a href="http://code.google.com/p/git-osx-installer/">Git Installer for OS X</a></li>
<li><a href="http://git.or.cz/course/svn.html">Git Crash Course for SVN Users</a></li>
<ul>
<div id="crp_related"><h3>Related Posts:</h3><ul><li><a href="http://blog.smartlogicsolutions.com/2008/12/01/displaying-an-image-in-a-combobox/" rel="bookmark" class="crp_title">Displaying an Image in a ComboBox</a></li><li><a href="http://blog.smartlogicsolutions.com/2010/02/01/setting-up-ubuntu-9-10-for-ruby-on-rails-development/" rel="bookmark" class="crp_title">Setting Up Ubuntu 9.10 for Ruby On Rails Development</a></li><li><a href="http://blog.smartlogicsolutions.com/2008/08/04/introducing-environmentalize-an-intuitive-environment-focused-config-structure-for-your-rails-applications/" rel="bookmark" class="crp_title">Introducing environmentalist: an intuitive, environment-focused config structure for your rails applications</a></li><li><a href="http://blog.smartlogicsolutions.com/2008/12/05/introducing-puremvcgen-an-ant-based-puremvc-flex-generator/" rel="bookmark" class="crp_title">Introducing PureMVCGen &#8211; an ANT based PureMVC Flex Generator</a></li><li><a href="http://blog.smartlogicsolutions.com/2008/06/07/subversion-timestamps-capistrano-finalize_update/" rel="bookmark" class="crp_title">Subversion Timestamps + Capistrano finalize_update</a></li><li>Powered by <a href="http://ajaydsouza.com/wordpress/plugins/contextual-related-posts/">Contextual Related Posts</a></li></ul></div>]]></content:encoded>
			<wfw:commentRss>http://blog.smartlogicsolutions.com/2008/12/10/getting-git-svn-to-run-on-os-x/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Introducing PureMVCGen &#8211; an ANT based PureMVC Flex Generator</title>
		<link>http://blog.smartlogicsolutions.com/2008/12/05/introducing-puremvcgen-an-ant-based-puremvc-flex-generator/</link>
		<comments>http://blog.smartlogicsolutions.com/2008/12/05/introducing-puremvcgen-an-ant-based-puremvc-flex-generator/#comments</comments>
		<pubDate>Fri, 05 Dec 2008 21:47:04 +0000</pubDate>
		<dc:creator>Greg Jastrab</dc:creator>
				<category><![CDATA[AS3]]></category>
		<category><![CDATA[Greg Jastrab]]></category>
		<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[ANT]]></category>
		<category><![CDATA[Flex]]></category>
		<category><![CDATA[gem]]></category>
		<category><![CDATA[generator]]></category>
		<category><![CDATA[git]]></category>
		<category><![CDATA[PureMVC]]></category>

		<guid isPermaLink="false">http://blog.smartlogicsolutions.com/?p=409</guid>
		<description><![CDATA[I just published a PureMVC code generation tool I&#8217;ve been working on lately. It&#8217;s an ANT-based tool, but is distributed via Ruby Gems, which allows it to be easily installed as a command-line tool once you have Ruby, rubygems, and ANT installed. Once you have those programs installed, simply enter ($> just denotes you are [...]]]></description>
			<content:encoded><![CDATA[<p>I just published a <a href="http://www.puremvc.org">PureMVC</a> code generation tool I&#8217;ve been working on lately.  It&#8217;s an ANT-based tool, but is distributed via <a href="http://rubygems.org">Ruby Gems</a>, which allows it to be easily installed as a command-line tool once you have <a href="http://www.ruby-lang.org">Ruby</a>, rubygems, and <a href="http://ant.apache.org">ANT</a> installed.</p>
<p>Once you have those programs installed, simply enter (<code>$></code> just denotes you are at a prompt on the command line)</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">$<span style="color: #000000; font-weight: bold;">&gt;</span> gem <span style="color: #c20cb9; font-weight: bold;">install</span> puremvc-gen</pre></div></div>

<p>and the tool will be installed.  Read on to see how to use it&#8230;</p>
<p><span id="more-409"></span></p>
<h4>Project Settings</h4>
<p>Presently, there is one bit of configuration housekeeping that must be done to get started using the tool.  Within the source directory of your project you will need to add a <b>proj.properties</b> file containing 5 property settings:</p>
<ul>
<li><b>app.prefix</b> =&gt; what to prefix your Facade and application Mediator with</li>
<li><b>project.name</b> =&gt; the name of your main MXML file </li>
<li><b>core.namespace</b> =&gt; the namespace of the project</li>
<li><b>core.dir</b> =&gt; the directory corresponding to the namespace (this will eventually be inferred from <b>core.namespace</b>)</li>
<li><b>pmvc.flavor</b> =&gt; <code>standard</code> | <code>multicore</code> (although only standard is currently supported)</li>
</ul>
<p>An example configuration for a project called <b>MyDemo</b> using the namespace <code>com.mydemo.demo</code> would look like:</p>
<h5>Example proj.properties</h5>

<div class="wp_syntax"><div class="code"><pre class="xml" style="font-family:monospace;">app.prefix = Demo
project.name = MyDemo
core.namespace = com.mydemo.demo
core.dir = com/mydemo/demo
pmvc.flavor = standard</pre></div></div>

<h4>Using PureMVCGen</h4>
<h5>Validating Project Properties</h5>
<p>If you are starting a new PureMVC project and you have the <b>proj.properties</b> file created in the source directory:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">$<span style="color: #000000; font-weight: bold;">&gt;</span> puremvc-gen check</pre></div></div>

<p>will ensure that the properties are correctly set.  If they have been, at the end of the ANT output, you should see:<br />
<div id="attachment_418" class="wp-caption alignnone" style="width: 428px"><img src="http://blog.smartlogicsolutions.com/wp-content/uploads/2008/12/validated.png" alt="Display showing properties have been validated" title="Properties Validated" width="418" height="71" class="size-full wp-image-418" /><p class="wp-caption-text">Display showing properties have been validated</p></div></p>
<h5>Generating the PureMVC Skeleton</h5>
<p>To generate the PureMVC directories, main MXML file, Facade, main Mediator, StartupCommand, and PrepareActorsCommand classes, simply enter:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">$<span style="color: #000000; font-weight: bold;">&gt;</span> puremvc-gen init</pre></div></div>

<p>After this was run successfully the directory hierarchy will look something like this:<br />
<div id="attachment_421" class="wp-caption aligncenter" style="width: 284px"><img src="http://blog.smartlogicsolutions.com/wp-content/uploads/2008/12/skeleton.png" alt="PureMVC skeleton generated from demo project properties" title="Generated PureMVC Skeleton" width="274" height="250" class="size-full wp-image-421" /><p class="wp-caption-text">PureMVC skeleton generated from demo project properties</p></div></p>
<h5>Other Commands</h5>
<p>I haven&#8217;t created any online documentation yet, but the tool has fairly decent instructions on the command line.</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">$<span style="color: #000000; font-weight: bold;">&gt;</span> puremvc-gen <span style="color: #7a0874; font-weight: bold;">help</span></pre></div></div>

<p><a href="http://blog.smartlogicsolutions.com/wp-content/uploads/2008/12/instructions.png"><img src="http://blog.smartlogicsolutions.com/wp-content/uploads/2008/12/instructions.png" alt="Instructions output on command line when running \&quot;help\&quot;" title="PureMVCGen Instructions" width="500" height="127" class="size-full wp-image-423" /></a><br />
A quick rundown of the command, proxy, and mediator generation commands:</p>
<ul>
<li><b>puremvc-gen new command</b> =&gt; generates a simple command</li>
<li><b>puremvc-gen new command -m</b> (or &#8211;macro) =&gt; generates a macro command</li>
<li><b>puremvc-gen new mediator</b> =&gt; generates a mediator</li>
<li><b>puremvc-gen new proxy</b> =&gt; generates a proxy</li>
</ul>
<p>All of these generation commands may be passed a <code>-n</code> option to specify the name for the class on the command line.  Otherwise, ANT will prompt you to input the name.</p>
<h4>Where to Git It</h4>
<p>The project is <a href="http://github.com/gjastrab/puremvc-gen/tree/master">hosted at github</a> so feel free to checkout the source.  I&#8217;ll update the README file eventually so that front page will have documentation as well.</p>
<p>The gem is also <a href="http://rubyforge.org/projects/gjastrab/">hosted at RubyForge</a> so you can download it there if you&#8217;d like to build it manually.</p>
<p>The GitHub page will eventually include a Roadmap for planned features, but please comment here with any suggestions you may have.</p>
<p>Finally, if you&#8217;re averse to Ruby you can always download the <b>conf/</b> directory of the project, and manually run the ANT commands.  They are a bit more cryptic though, which is why the gem and executable it provides are nice, however it should output instructions on what settings need to be made to run it manually.</p>
<p>Enjoy!</p>
<div id="crp_related"><h3>Related Posts:</h3><ul><li><a href="http://blog.smartlogicsolutions.com/2008/12/18/puremvcgen-011-released-now-works-on-windows/" rel="bookmark" class="crp_title">PureMVCGen 0.1.1 Released &#8211; Now Works on Windows</a></li><li><a href="http://blog.smartlogicsolutions.com/2008/07/15/compiling-your-first-flex-4-application/" rel="bookmark" class="crp_title">Compiling Your First Flex 4 Application</a></li><li><a href="http://blog.smartlogicsolutions.com/2008/11/12/watch-multiple-logs-in-a-single-terminal/" rel="bookmark" class="crp_title">Watch Multiple Logs in a Single Terminal</a></li><li><a href="http://blog.smartlogicsolutions.com/2008/08/21/getting-subclipse-to-work-in-gandymede-eclipse-34/" rel="bookmark" class="crp_title">Getting Subclipse to Work in Gandymede (Eclipse 3.4)</a></li><li><a href="http://blog.smartlogicsolutions.com/2008/10/14/facebox-with-prototype/" rel="bookmark" class="crp_title">Facebox With Prototype</a></li><li>Powered by <a href="http://ajaydsouza.com/wordpress/plugins/contextual-related-posts/">Contextual Related Posts</a></li></ul></div>]]></content:encoded>
			<wfw:commentRss>http://blog.smartlogicsolutions.com/2008/12/05/introducing-puremvcgen-an-ant-based-puremvc-flex-generator/feed/</wfw:commentRss>
		<slash:comments>9</slash:comments>
		</item>
	</channel>
</rss>

