<?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>Shaun Smith &#187; tutorial</title>
	<atom:link href="http://shaun.boyblack.co.za/blog/tag/tutorial/feed/" rel="self" type="application/rss+xml" />
	<link>http://shaun.boyblack.co.za/blog</link>
	<description>Flex, Ruby, Mongo - London, UK</description>
	<lastBuildDate>Sat, 04 Feb 2012 17:39:55 +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>Getting Started with Git on Mac OS X</title>
		<link>http://shaun.boyblack.co.za/blog/2009/03/14/getting-started-with-git-on-mac-os-x/</link>
		<comments>http://shaun.boyblack.co.za/blog/2009/03/14/getting-started-with-git-on-mac-os-x/#comments</comments>
		<pubDate>Sat, 14 Mar 2009 18:42:32 +0000</pubDate>
		<dc:creator>shaun</dc:creator>
				<category><![CDATA[Resources]]></category>
		<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[eclipse]]></category>
		<category><![CDATA[git]]></category>
		<category><![CDATA[mac]]></category>
		<category><![CDATA[osx]]></category>
		<category><![CDATA[scm]]></category>
		<category><![CDATA[svn]]></category>
		<category><![CDATA[tutorial]]></category>

		<guid isPermaLink="false">http://shaun.boyblack.co.za/blog/?p=224</guid>
		<description><![CDATA[Some Background I&#8217;ve recently switched from using SVN to using Git as my source control management tool of choice. It took a little while to get to grips with, but it rocks! Git is not an evolution of SVN. It is entirely different. Git is a distributed revision control system &#8211; everybody working on a project has their own full copy of the repository and its entire history. Git does not require the presence of a network connection: most commands &#8230; <a href="http://shaun.boyblack.co.za/blog/2009/03/14/getting-started-with-git-on-mac-os-x/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p><strong>Some Background</strong></p>
<p>I&#8217;ve recently switched from using SVN to using <a title="Git SCM" href="http://git-scm.com/" target="_blank">Git</a> as my source control management tool of choice. It took a little while to get to grips with, but it rocks!</p>
<p>Git is not an evolution of SVN. It is entirely different. Git is a distributed revision control system &#8211; everybody working on a project has their own full copy of the repository and its entire history.<span id="more-224"></span></p>
<p>Git does not require the presence of a network connection: most commands in Git operate locally, allowing you to review your project history, make branches and tags, merge changes, but most importantly, allowing you to commit while offline.</p>
<p>If you&#8217;ve used SVN you&#8217;ve probably noticed the littering of .svn folders across your entire project tree, requiring the need for an export tool to retrieve clean copies of your code, and introducing problems when you delete, rename or move files or folders in your project. Git takes a slightly more sensible approach: it creates one folder (named .git) in the root folder of your project.<strong></strong></p>
<p><strong>Git Concepts</strong></p>
<p>With Git there are 3 important things to be aware of: the Git object database, the &#8220;index&#8221;, and your working area.</p>
<p>The Git object database contains a bunch of stuff that you typically don&#8217;t need to worry about. Essentially it&#8217;s the repository.</p>
<p>Your working area is the collection of files currently sitting in your project folder. You should treat these files as if they are temporary &#8211; because they are! Things you want to keep should be committed to the repository.</p>
<p>The Index is sometimes referred to as the Staging Area. It&#8217;s a list of what will get stored on your next commit. Conceptually it sits between your working files and the Git object database. Files that haven&#8217;t been staged to the index will be ignored when doing a commit. This gives you great control over what gets committed when.</p>
<p>A branch is a cheap copy of a particular state of the Git object database. Branches are easy to create and switch between, giving you a safe way to try out ideas quickly and easily. Switching to another branch updates your working area to reflect the state of that branch &#8211; this is why you should consider your working area temporary.</p>
<p><strong>Installing Git on Mac OS X</strong></p>
<p>Grab and install the latest OS-X Installer from:</p>
<p><a title="Git OSX Installer" href="http://code.google.com/p/git-osx-installer/" target="_blank">http://code.google.com/p/git-osx-installer/</a></p>
<p><strong>Configuring Git</strong></p>
<p>You need to tell Git who you are &#8211; it uses this information for your commits etc.</p>
<p>Fire up your terminal, and type:</p>
<pre>git config --global user.name "Your Name"
git config --global user.email your@email.com</pre>
<p><strong>Using Git</strong></p>
<p>Once Git is installed on your system, creating a Git repository is easy: open your terminal, cd into the root folder of your project, and type: git init</p>
<p>That&#8217;s pretty much it!</p>
<p>After initialising your Git repository, it will most likely be empty. In order to commit files to the repository you first need to &#8220;stage&#8221; them by adding them to the index. To add all the files in your current project to the index type:</p>
<pre>git add .</pre>
<p>To commit these files type:</p>
<pre>git commit -m "your commit message"</pre>
<p>To view the status of your repository type:</p>
<pre>git status</pre>
<p><strong>To Summarise</strong></p>
<p>[<a title="Git OSX Installer" href="http://code.google.com/p/git-osx-installer/" target="_blank">Download and install Git</a>]<br />
[cd into the root of your project]</p>
<pre>
git init
ls -la
git status
git add .
git status
git commit -m "a useful commit message"
git status
</pre>
<p>[change some files in your working area]</p>
<pre>
git status
git diff
git commit -a -m "commit message. -a adds all files from your working area to the index"
git status
</pre>
<p>[delete some files from your local working area]</p>
<pre>
git status
git add -u
git commit -m "commit message. -u adds deleted files to the index"
git status
</pre>
<p><strong>Ignoring Files</strong></p>
<p>You will probably want to ensure than certain files don&#8217;t ever get committed to the repo:</p>
<p><a title="Git Ignore" href="http://www.kernel.org/pub/software/scm/git/docs/gitignore.html" target="_blank">http://www.kernel.org/pub/software/scm/git/docs/gitignore.html</a></p>
<p><strong>Extra Configuration</strong></p>
<p>You can enabled colorful output:</p>
<pre>
git config --global color.diff auto
git config --global color.status auto
git config --global color.branch auto
</pre>
<p><strong>Some Bundled Visual Tools</strong></p>
<pre>
gitk
git gui
</pre>
<p><strong>Git Screencasts</strong></p>
<p><a title="Git Screencasts" href="http://gitcasts.com/" target="_blank">http://gitcasts.com/</a></p>
<p><strong>Installing Git on Windows</strong></p>
<p><a title="Installing Git on Windows" href="http://gitcasts.com/posts/git-on-windows" target="_blank">http://gitcasts.com/posts/git-on-windows</a></p>
<p><strong>Some Other Git Links</strong></p>
<ul>
<li><a title="Git Source Control Management" href="http://git-scm.com/" target="_blank">http://git-scm.com/</a></li>
<li><a title="Understanding Git Conceptually" href="http://www.eecs.harvard.edu/~cduan/technical/git/" target="_blank">http://www.eecs.harvard.edu/~cduan/technical/git/</a></li>
<li> <a href="http://git.or.cz/index.html" target="_blank">http://git.or.cz/index.html</a></li>
<li><a href="http://git.or.cz/course/svn.html" target="_blank">http://git.or.cz/course/svn.html</a></li>
<li><a title="Git FAQ" href="http://git.or.cz/gitwiki/GitFaq" target="_blank">http://git.or.cz/gitwiki/GitFaq</a></li>
<li><a title="Github Learning Resource" href="http://learn.github.com/" target="_blank">http://learn.github.com/</a></li>
<li><a title="Git OSX Installer" href="http://code.google.com/p/git-osx-installer/" target="_blank">http://code.google.com/p/git-osx-installer/</a></li>
<li><a title="Git User Manual" href="http://www.kernel.org/pub/software/scm/git/docs/user-manual.html" target="_blank">http://www.kernel.org/pub/software/scm/git/docs/user-manual.html</a></li>
<li><a title="The Thing About Git" href="http://tomayko.com/writings/the-thing-about-git" target="_blank">http://tomayko.com/writings/the-thing-about-git</a></li>
<li><a title="Git Talk" href="http://video.google.com/videoplay?docid=-3999952944619245780" target="_blank">http://video.google.com/videoplay?docid=-3999952944619245780</a></li>
</ul>
<p><strong>Eclipse Integration</strong></p>
<p>Point your eclipse update manager to: <a title="EGit" href="http://www.jgit.org/update-site" target="_blank">http://www.jgit.org/update-site</a></p>
<p>More info: <a title="JGit" href="http://www.jgit.org/" target="_blank">http://www.jgit.org/</a></p>
<p><strong>Some Commands</strong></p>
<p><em>Add all working files to the index:</em></p>
<pre>git add .</pre>
<p><em>Add deleted files to the index:</em></p>
<pre>git add -u</pre>
<p><em>Create and switch to a new branch:</em></p>
<pre>git checkout -b newbranchname</pre>
<p><em>Review last commit:</em></p>
<pre>
git show
git show --stat
git show --name -status
git show HEAD
</pre>
<p><em>Review commit history:</em></p>
<pre>
git log
git log tag..branch
git log -10
git log --since="May 1" --until="June 1"
git log --author=fred
git log -- some/file
</pre>
<p><em>Creating branches:</em></p>
<pre>
git branch name
git branch name commit
</pre>
<p><em>Switching branches:</em></p>
<pre>
git checkout name
git checkout -f name
</pre>
]]></content:encoded>
			<wfw:commentRss>http://shaun.boyblack.co.za/blog/2009/03/14/getting-started-with-git-on-mac-os-x/feed/</wfw:commentRss>
		<slash:comments>20</slash:comments>
		</item>
		<item>
		<title>Getting Started with FlashDevelop3 and AS3</title>
		<link>http://shaun.boyblack.co.za/blog/2008/03/08/getting-started-with-flashdevelop3-and-as3/</link>
		<comments>http://shaun.boyblack.co.za/blog/2008/03/08/getting-started-with-flashdevelop3-and-as3/#comments</comments>
		<pubDate>Sat, 08 Mar 2008 00:53:24 +0000</pubDate>
		<dc:creator>shaun</dc:creator>
				<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[actionscript]]></category>
		<category><![CDATA[as3]]></category>
		<category><![CDATA[flash]]></category>
		<category><![CDATA[flashdevelop]]></category>
		<category><![CDATA[flexsdk]]></category>
		<category><![CDATA[swc]]></category>
		<category><![CDATA[tutorial]]></category>

		<guid isPermaLink="false">http://shaun.boyblack.co.za/blog/2008/03/08/getting-started-with-flashdevelop3-and-as3/</guid>
		<description><![CDATA[Aha! Finally. Time for my first tutorial: Getting up and running with FlashDevelop3. Firstly, FlashDevelop 3 only runs on Windows XP/Vista, and requires the .NET 2 runtime. Additionally, to compile AS3 code you will need the Java 1.6 runtime and the Adobe Flex SDK. Ok, let&#8217;s go! Part 1 &#8211; Downloading, Installing, and Compiling a SWF Let&#8217;s begin by setting things up and compiling our first SWF. Download the Adobe Flex SDK (just the Flex 3 SDK, not Flex Builder), &#8230; <a href="http://shaun.boyblack.co.za/blog/2008/03/08/getting-started-with-flashdevelop3-and-as3/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Aha! Finally. Time for my first tutorial: Getting up and running with <a title="FlashDevelop" href="http://www.flashdevelop.org/" target="_blank">FlashDevelop3</a>.</p>
<p>Firstly, FlashDevelop 3 only runs on Windows XP/Vista, and requires the .NET 2 runtime. Additionally, to compile AS3 code you will need the Java 1.6 runtime and the <a title="Adobe Flex SDK" href="http://www.adobe.com/go/flex3_sdk" target="_blank">Adobe Flex SDK</a>. Ok, let&#8217;s go!</p>
<p><span id="more-49"></span></p>
<p><strong>Part 1 &#8211; Downloading, Installing, and Compiling a SWF</strong></p>
<p>Let&#8217;s begin by setting things up and compiling our first SWF.</p>
<ol>
<li>Download the <a title="Adobe Flex SDK" href="http://www.adobe.com/go/flex3_sdk" target="_blank">Adobe Flex SDK</a> (just the Flex 3 SDK, not Flex Builder), and unpack it somewhere easy to find (C:FlexSDKFlex3).</li>
<li>Download the latest version of <a title="FlashDevelop" href="http://www.flashdevelop.org/community/viewforum.php?f=11" target="_blank">FlashDevelop</a>, install it and run it.</li>
<li>Create a New Project, under ActionScript 3 choose Default Project, and give it a name (&#8220;hello&#8221;).</li>
<li>In the Project Panel expand the &#8220;src&#8221; folder and open up &#8220;Main.as&#8221;</li>
<li>In the constructor add the code: trace(&#8220;hello world!&#8221;);</li>
<li>Hit Ctrl-Enter (or F5). A dialog should pop up asking if you&#8217;d like to open the AS3 context settings. Click &#8220;OK&#8221;.</li>
<li>In the &#8220;Flex SDK Location&#8221; input field enter the path from step 1 (or browse to it).</li>
<li>Hit Ctrl-Enter again. This should compile your code into a SWF and launch it in a tab. The Flex 3 compiler does incremental compiling, so the first compile might take a while, but subsequent compiles should be much faster.</li>
<li>Make a &#8220;whooping&#8221; noise! &#8220;hello world!&#8221; should be displayed in the Output panel. You&#8217;ll find the SWF sitting in the &#8220;bin&#8221; folder. Notice that the project panel let&#8217;s you look into the guts of your SWF.. pretty damn sweet!</li>
</ol>
<p><strong>Part 2 &#8211; Some Adjustments</strong></p>
<p>By default, FlashDevelop launches SWFs in it&#8217;s own version of the Flash Player. At the time of this writing, the player doesn&#8217;t perform quite as well as the <a title="Adobe Flash Player" href="http://www.adobe.com/support/flashplayer/downloads.html" target="_blank">official debug version of the Adobe Flash Player</a> (besides, we want all the goodness of the very latest Flash Player!). Also, I find the tabbed view weird. So let&#8217;s change our setup a bit.</p>
<ol>
<li>Head on over to <a title="Adobe Flash Player" href="http://www.adobe.com/support/flashplayer/downloads.html" target="_blank">Adobe downloads</a>, &#8220;Download the Windows Flash Player 9 Projector content debugger&#8221; and put it somewhere easy to find (C:FlexSDKFlashPlayer)</li>
<li>Back in FlashDevelop, go to the main menu, click &#8220;Tools&#8221; and select &#8220;Program Settings&#8221; (or hit F10)</li>
<li>In the left panel, under &#8220;Plugins&#8221; select FlashViewer, and point the &#8220;External Play Path&#8221; to the debug player executable from step 1.</li>
<li>While you&#8217;re there, change the &#8220;Movie Display Style&#8221; to &#8220;External&#8221;. Click &#8220;Close&#8221;.</li>
<li>At the top of the Project Panel click the &#8220;Project Properties&#8221; button (third from the left).</li>
<li>Under &#8220;Test Movie&#8221; change the selection to &#8220;Play in external player&#8221;, and click &#8220;OK&#8221;.</li>
<li>Hit Ctrl-Enter. Make the universal &#8220;Whazzamm&#8221; sound!</li>
</ol>
<p><strong>Part 3 &#8211; Attaching Assets to the Stage</strong></p>
<p>Perhaps &#8220;hello world!&#8221; is not that thrilling for you. Fine.</p>
<ol>
<li>Create a folder called &#8220;lib&#8221; inside your project folder (alongside &#8220;bin&#8221; and &#8220;src&#8221;).</li>
<li>Fire up Adobe Flash CS3 and create a new Flash File (Action Script 3.0).</li>
<li>Save it inside the &#8220;lib&#8221; folder from step 1 and call it &#8220;assets.fla&#8221;.</li>
<li>In the Flash IDE grab the Oval tool and draw a circle.</li>
<li>Select the circle and convert it to a symbol by hitting F8 (or right-click and select &#8220;Convert to Symbol&#8230;&#8221;).</li>
<li>Give it the name &#8220;Circle&#8221; and expand the Linkage panel by clicking &#8220;Advanced&#8221;.</li>
<li>Under &#8220;Linkage&#8221; tick &#8220;Export for ActionScript&#8221; and click &#8220;OK&#8221;.</li>
<li>Open up your Publish Settings (Ctrl-Shift-F12), deselect &#8220;HTML&#8221;, and flip to the &#8220;Flash&#8221; tab</li>
<li>Tick &#8220;Export SWC&#8221;, click &#8220;Publish&#8221; and click &#8220;OK&#8221;.</li>
<li>Save the file and close the Flash IDE.</li>
<li>Flip back to FlashDevelop, and expand the &#8220;lib&#8221; folder in the Project Panel.</li>
<li>Right-click &#8220;assets.swc&#8221; and select &#8220;Add To Library&#8221;.</li>
<li>Replace our &#8220;trace&#8221; statement with the following code:<br />
var circle:Circle = new Circle();<br />
addChild( circle );</li>
<li>Hit Ctrl-Enter. Loudly exclaim &#8220;Golly, this is the biznis!&#8221;.</li>
</ol>
<p><strong>Part 4 &#8211; Extending Assets, Adding Interactivity</strong></p>
<p>Perhaps a plain old circle on the stage doesn&#8217;t really do it for you. You want some motion. You want some interactivity. Some filters. Fine then. Let&#8217;s do it..</p>
<ol>
<li>In the Project Panel, right click the &#8220;src&#8221; folder, select &#8220;New&#8221; &#8220;Class&#8221;, name it &#8220;ReactiveCircle&#8221; and click &#8220;OK&#8221;.</li>
<li>Head to the end of the line &#8220;public class ReactiveCircle&#8221;, type &#8220;extends&#8221;, hit Space and select &#8220;Circle&#8221;.</li>
<li>In the constructor type &#8220;filters = [new DropShadowFilter()];&#8221;</li>
<li>On the next line type &#8220;addEventListener(&#8221; and press Ctrl-Alt-Space (this enables autocompletion for all available classes, not just the imported ones). Start typing &#8220;MouseEvent&#8221; but hit Enter as soon as you see it selected. Complete the statement with &#8220;.CLICK, onClick);&#8221;</li>
<li>Move your cursor back onto the word &#8220;onClick&#8221;, press Ctrl-Shift-1 and hit Enter.</li>
<li>Inside the generated event handler add the code: x += 10;</li>
<li>Flip back to the Main class and change:<br />
var circle:Circle = new Circle();<br />
to<br />
var circle:ReactiveCircle = new ReactiveCircle();</li>
<li>Hit Ctrl-Enter. Click the circle. Shout &#8220;Kapoww!&#8221;</li>
</ol>
<p>Ok, it&#8217;s not a fully fledged RIA, but it should be enough to get you started.</p>
<p>Happy Flashing!</p>
<p><a title="FlashDevelop hello project" href="http://shaun.boyblack.co.za/blog/wp-content/uploads/2008/03/hello.zip">FlashDevelop hello project</a></p>
]]></content:encoded>
			<wfw:commentRss>http://shaun.boyblack.co.za/blog/2008/03/08/getting-started-with-flashdevelop3-and-as3/feed/</wfw:commentRss>
		<slash:comments>16</slash:comments>
		</item>
		<item>
		<title>The Begining</title>
		<link>http://shaun.boyblack.co.za/blog/2007/12/12/hello-world/</link>
		<comments>http://shaun.boyblack.co.za/blog/2007/12/12/hello-world/#comments</comments>
		<pubDate>Wed, 12 Dec 2007 19:39:54 +0000</pubDate>
		<dc:creator>shaun</dc:creator>
				<category><![CDATA[Banter]]></category>
		<category><![CDATA[actionscript]]></category>
		<category><![CDATA[flash]]></category>
		<category><![CDATA[flashdevelop]]></category>
		<category><![CDATA[papervision3d]]></category>
		<category><![CDATA[puremvc]]></category>
		<category><![CDATA[tutorial]]></category>
		<category><![CDATA[tweener]]></category>
		<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://shaun.boyblack.co.za/blog/?p=1</guid>
		<description><![CDATA[Word up! As in.. WordPress up and running! So, my plan is to throw up some tutorials here. The kind that would have helped me a bunch when I started on my journey into OO flash development. I want to cover FlashDevelop, Tweener, Papervision3D and PureMVC amongst other flash/web related things. I&#8217;m also going to use this site as a portfolio of sorts. When I get the time I&#8217;m going to look into building a flash portfolio that uses this &#8230; <a href="http://shaun.boyblack.co.za/blog/2007/12/12/hello-world/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Word up! As in.. <a href="http://wordpress.com/" title="WordPress" target="_blank">WordPress</a> up and running!</p>
<p>So, my plan is to throw up some tutorials here. The kind that would have helped me a bunch when I started on my journey into OO flash development.</p>
<p>I want to cover <a href="http://www.flashdevelop.org/" title="Flash Develop" target="_blank">FlashDevelop</a>, <a href="http://code.google.com/p/tweener/" title="Tweener" target="_blank">Tweener</a>, <a href="http://www.papervision3d.org" title="Papervision3D" target="_blank">Papervision3D</a> and <a href="http://puremvc.org" title="PureMVC">PureMVC</a> amongst other flash/web related things.</p>
<p>I&#8217;m also going to use this site as a portfolio of sorts. When I get the time I&#8217;m going to look into building a flash portfolio that uses this site as it&#8217;s CMS.</p>
]]></content:encoded>
			<wfw:commentRss>http://shaun.boyblack.co.za/blog/2007/12/12/hello-world/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>

