<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">

 <title>Spaceghost@Github</title>
 <link href="http://spacegho.st/atom.xml" rel="self"/>
 <link href="http://spacegho.st/"/>
 <updated>2020-12-04T20:14:53+00:00</updated>
 <id>http://spacegho.st/</id>
 <author>
   <name>Johnneylee Jack Rollins</name>
   <email>me@spacegho.st</email>
 </author>

 
 <entry>
   <title>Working with rails edge</title>
   <link href="http://spacegho.st/Working-with-rails-edge"/>
   <updated>2011-08-25T00:00:00+00:00</updated>
   <id>http://Spacegho.st/Working-with-rails-edge</id>
   <content type="html">
</content>
 </entry>
 
 <entry>
   <title>Surrealizations</title>
   <link href="http://spacegho.st/Surrealizations"/>
   <updated>2011-08-21T00:00:00+00:00</updated>
   <id>http://Spacegho.st/Surrealizations</id>
   <content type="html">&lt;p&gt;I think I’ve forgotten how to talk. Honestly, being&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>How to get help</title>
   <link href="http://spacegho.st/How-to-get-help"/>
   <updated>2011-05-28T00:00:00+00:00</updated>
   <id>http://Spacegho.st/How-to-get-help</id>
   <content type="html">&lt;p&gt;Notice:
&lt;span class=&quot;meta&quot;&gt;This blargpost was &lt;span class=&quot;strike&quot;&gt;stolen&lt;/span&gt;^W adapted from&lt;/span&gt; &lt;a href=&quot;http://diveintomark.org/archives/2003/05/05/why_we_wont_help_you&quot;&gt;Why we won’t help you.&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;TL;DR Read the cucumber feature.&lt;/p&gt;

&lt;div class=&quot;require&quot;&gt;&lt;a href=&quot;http://cukes.info&quot; title=&quot;cukes.info&quot;&gt;cucumber&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;feature&quot;&gt;Get help&lt;br /&gt;
&lt;tab /&gt;&lt;span&gt;In order&lt;/span&gt; to get help from my peers&lt;br /&gt;
&lt;tab /&gt;&lt;span&gt;As a&lt;/span&gt; developer&lt;br /&gt;
&lt;tab /&gt;&lt;span&gt;I want&lt;/span&gt; to do &lt;a href=&quot;https://gist.github.com/&quot; title=&quot;Gist&quot;&gt;all&lt;/a&gt; I can to &lt;a href=&quot;https://gist.github.com/996779&quot; title=&quot;How to ask questions&quot;&gt;help&lt;/a&gt; them &lt;a href=&quot;http://www.catb.org/~esr/faqs/smart-questions.html&quot; title=&quot;Smart questions&quot;&gt;help&lt;/a&gt; me&lt;/div&gt;

&lt;p&gt;Now here’s a scenario you might be familiar with.
You might’ve seen it on IRC, forums, &lt;a href=&quot;http://stackoverflow.com/&quot;&gt;Stack Overflow&lt;/a&gt;, mailing lists, any number of places.&lt;/p&gt;

&lt;p&gt;Let’s pretend you’re on IRC and someone new asks for help and you know they’re new because you’re a lurker like me and don’t ever sleep.
They’re asking for some help with their model validations, and by golly, someone beats you to helping. Or so it seems.&lt;/p&gt;

&lt;p&gt;The conversation goes thusly.&lt;/p&gt;

&lt;p&gt;Helper: “Please elaborate by showing us the code by making a gist of the issue. (&lt;a href=&quot;https://gist.github.com/&quot; title=&quot;Gist@Github&quot;&gt;https://gist.github.com/&lt;/a&gt;)&lt;/p&gt;

&lt;p&gt;The new person promptly returns with a gist.
As you start to shift gears from being super extra velocitous (New word!) to trying to help explain validations to a newcomer, you take a peek at their gist.
No, I’m going to call it the gist from hell. To call that a gist is a detriment to all gisters everywhere… on github.
It’s a veritable explosion of what might have resembled properly formatted code, had it not gone three rounds with the business end of a lawn mower.&lt;/p&gt;

&lt;p&gt;Now with you being a smart cookie and all, you back away and pretend you were never here. (It’s okay, I do it too.) No one responds to the poor guy who simply needed some help.
It’s like everyone forgot he existed.&lt;/p&gt;

&lt;p&gt;Luckily, there’s one cheeky fellow in the channel (usually me) who pipes up and responds with “Hey, that is honestly some of the worst code I’ve seen in a while, you should go and format it, clean it up and make it easier for us to help you with it.”&lt;/p&gt;

&lt;p&gt;Okay, so if this isn’t all that common a story it’s likely because it all happened to me. There’s still a lesson to learn!&lt;/p&gt;

&lt;p&gt;Why can’t this poor fellow get some help? Well, the snarky answer would be that we’ve helped him a great deal already.
If you’re not as zen as I am about these things, here’s a more detailed explanation why his pleas for help went unheard.&lt;/p&gt;

&lt;ol class=&quot;inner&quot;&gt;
  &lt;li&gt;&lt;strong&gt;Formatting your code may reveal your problem.&lt;/strong&gt;&lt;p&gt;Many cases of &quot;Ohmygawsh I have no idea what's wrong!&quot; is caused by silly developer errors.
  Typos like putting the colon in the wrong place (especially when using that darned new-fangled hash syntax) can really be embarassing at times.
  Usually simple errors like this and many others are mitigated by formatting your code according to the best practices of the community.
  In ruby this means two spaces per tab, make sure they're inserted as spaces.&lt;/p&gt;

  &lt;p&gt;Now, I'm not saying that your code will work after you've formatted it appropriately; it may or may not.
  I'm also not going to say that there aren't developers out there who can't scrape the insides of a garbage disposal and come out with a perfectly valid program out of it.
  But organising your code into a format that has been deemed readable by the community surrounding the language/framework/whatever you're trying to get help with is likely the best approach.&lt;/p&gt;

  &lt;p&gt;Not to put too much work on you, but if you were willing to accept a friendly suggestion, I'd say to learn how to code in that very way we just covered.
  Write your code in the format that the community can read. You'll love you for it when you need help or want to show off your code.&lt;/p&gt;&lt;/li&gt;

&lt;li&gt;&lt;strong&gt;Formatting your code may solve your problem.&lt;/strong&gt;&lt;p&gt;One possibility that may happen as you make sure your code is readable, you might happen on the problematic code and find that it was just a missing comma. This is a Major Win&amp;#8482;&lt;/p&gt;&lt;/li&gt;

&lt;li&gt;&lt;strong&gt;Knowing your communication tools.&lt;/strong&gt;&lt;p&gt;It's not only good enough that you make your code seemingly gorgeous, you've got to share it.
  My personal favorite tool for all things pastable, at least text-wise, is &lt;a href=&quot;https://gist.github.com/&quot; title=&quot;Gist@Github&quot;&gt;Gist&lt;/a&gt;.
  Now making a good gist of your code is crucial and may impinge heavily on whether you'll get help or not.&lt;/p&gt;

  &lt;p&gt;If you'd like a good tutorial on using gist that's hosted on gist and likely written on it as well, &lt;a href=&quot;https://github.com/radar/guides/blob/master/using-gist.md&quot; title=&quot;Using Gist&quot;&gt;this&lt;/a&gt; is a great example.&lt;/p&gt;

  &lt;p&gt;Knowing how to ask for help is also a very important skill. One that really is easier to learn by doing than reading. One thing you want to be aware of is both spotting and not being a 'help vampire'. Here's a &lt;a href=&quot;http://slash7.com/2006/12/22/vampires/&quot; title=&quot;Help Vampires: A spotter's guide&quot;&gt;link&lt;/a&gt;.&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Now, please go forth and imbue the world with many such niceties as lovely gems, LOC’s by the dozen (Hehe, joke about ruby not taking copious amounts lines to do trivial things), and instill a mindset of a curteous coder.&lt;/p&gt;

&lt;p&gt;~Johnneylee&lt;/p&gt;

</content>
 </entry>
 
 <entry>
   <title>Baby steps</title>
   <link href="http://spacegho.st/Baby-steps"/>
   <updated>2011-05-28T00:00:00+00:00</updated>
   <id>http://Spacegho.st/Baby-steps</id>
   <content type="html">&lt;p&gt;So, you may have noticed that I’ve been off in my own little world with &lt;a href=&quot;https://github.com/Spaceghost/Monoceros&quot; title=&quot;Monoceros@Github&quot;&gt;Monoceros&lt;/a&gt;.
I’ve been trying to become a bit more competent at the tools that I use before pushing out initial tests for you to peruse.
But you know what? Screw you. I mean this in the nicest way, I really do.&lt;/p&gt;

&lt;p&gt;What I really meant to say was, “Hey, I really appreciate you a lot. But I really need to just get code out there, and I know it won’t be the best.”
You know what? That makes me feel liberated. Not that I don’t care what you think, this is more of a personal victory than some petty realization.
I’ll just toss out tests and features and get some feedback, that’s safe right? You won’t bite me, won’t you?&lt;/p&gt;

&lt;p&gt;With that said, I think it’s safe enough to point out that my test will suck.
I’m trying to be clever, writing tests for metaprogramming sounds so daunting. Perhaps painful?&lt;/p&gt;

&lt;p&gt;Thank you for conspiring with me against myself,&lt;/p&gt;

&lt;p&gt;~Johnneylee&lt;/p&gt;

</content>
 </entry>
 
 <entry>
   <title>Coding dangerously</title>
   <link href="http://spacegho.st/Coding-dangerously"/>
   <updated>2011-05-27T00:00:00+00:00</updated>
   <id>http://Spacegho.st/Coding-dangerously</id>
   <content type="html">&lt;p&gt;I spend a lot of time in the #RubyonRails channel on Freenode.
Sometimes a certain subject comes up that I have problems refraining from answering, or attempting to.
That question goes invariably like, “… debugger …”&lt;/p&gt;

&lt;p&gt;I ommited the parts that aren’t important right now, my mind is already making a sad face.
I start to wonder if it’s conviction or something sinister that gives me such a distaste for debuggers.
The way I feel about debuggers is that you should be comfortable enough with the language to be able to write quick throw-away code to investigate the problem if you’re able to use the debugger with any skill whatsoever.&lt;/p&gt;

&lt;p&gt;Perhaps that’s an unrealistic goal, but I digress. “Coding dangerously”, besides sounding like the newest hip craze you hooligans are into,
is a practice of realizing it’s perfectly fine to write code you intend to throw away once you’ve found the information you needed.&lt;/p&gt;

&lt;p&gt;Why would I want to write code I intend on tossing out? Well, that’s a good question.
It may boil down to personal taste, but right now I’m on the soapbox.
I find that I’m able to keep my present &lt;a name=&quot;velocity&quot; title=&quot;Velocity is an extremely simple, powerful method for accurately measuring the rate at which teams consistently deliver business value.&quot;&gt;velocity&lt;/a&gt;
when I take a moment to root around the program and get the data I need instead of dropping into ruby’s debugger.&lt;/p&gt;

&lt;p&gt;My preferred methods of getting to the juicy bits of my program will likely always be &lt;a href=&quot;http://rubydoc.info/stdlib/core/1.9.2/Object#inspect-instance_method&quot; title=&quot;#inspect@Rubydoc.info&quot;&gt;#inspect&lt;/a&gt;, &lt;a href=&quot;http://rubydoc.info/stdlib/core/1.9.2/Object#instance_variables-instance_method&quot; title=&quot;#instance_variables@Rubydoc.info&quot;&gt;#instance_variables&lt;/a&gt;, and &lt;a href=&quot;http://rubydoc.info/stdlib/logger/1.9.2/Logger/Application#logger-instance_method&quot; title=&quot;#logger@Rubydoc.info&quot;&gt;#logger&lt;/a&gt; from the stdlib as well as &lt;a href=&quot;http://rubydoc.info/docs/rails/3.0.0/ActionView/Helpers/DebugHelper#debug-instance_method&quot; title=&quot;#debug@RubyonRails&quot;&gt;#debug&lt;/a&gt; in &lt;a href=&quot;http://rubyonrails.org/&quot; title=&quot;Ruby on Rails&quot;&gt;Ruby on Rails&lt;/a&gt;.
Examples of their uses can be found on the rails guide for &lt;a href=&quot;http://guides.rubyonrails.org/debugging_rails_applications.html&quot; title=&quot;Debugging Rails Applications@RubyonRails&quot;&gt;debugging&lt;/a&gt;. I’ll check back in later for some more advanced techniques for coding dangerously.&lt;/p&gt;

&lt;p&gt;This is where we part ways for a while, I hope you enjoyed my mind as much as I do. Live long and code dangerously.&lt;/p&gt;

&lt;p&gt;&lt;a href=&quot;http://i.imgur.com/IBXFX.jpg&quot; title=&quot;Make it sew&quot;&gt;Make it sew&lt;/a&gt;,&lt;/p&gt;

&lt;p&gt;~Johnneylee&lt;/p&gt;

</content>
 </entry>
 
 <entry>
   <title>Ferris Bueller</title>
   <link href="http://spacegho.st/Ferris-Bueller"/>
   <updated>2011-05-25T00:00:00+00:00</updated>
   <id>http://Spacegho.st/Ferris-Bueller</id>
   <content type="html">&lt;p&gt;So, I was watching Ferris Bueller’s Day Off (“&lt;a href=&quot;http://www.imdb.com/title/tt0091042/&quot; title=&quot;FBDO@IMDB&quot;&gt;FBDO&lt;/a&gt;” to me and my friends). I had just seen [Fight Club][], and I was thinking about it. Here’s what I thought.&lt;/p&gt;

&lt;blockquote&gt;
  &lt;p&gt;“Sometimes, people just happen. They were friends one day, then the next, they’re strangers. Luckily thanks to evolution, a new friend joins your social circle. This is how single serving friend don’t hurt, this is how you can breathe each day.”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Honestly, I don’t know why I think this is in any way clever. I think I just amuse myself too much. If you’re so compelled, let me know what you think.&lt;/p&gt;

&lt;hr /&gt;
&lt;p class=&quot;meta&quot;&gt;Notice: My thoughts are free because I didn't think they were worth paying taxes for the penny.&lt;/p&gt;

&lt;p&gt;[Fight Club]: http://www.imdb.com/title/tt0137523/ “Fight Club@IMDB&lt;/p&gt;

</content>
 </entry>
 
 <entry>
   <title>Feature share</title>
   <link href="http://spacegho.st/Feature-share"/>
   <updated>2011-05-24T00:00:00+00:00</updated>
   <id>http://Spacegho.st/Feature-share</id>
   <content type="html">&lt;blockquote&gt;
  &lt;h2 id=&quot;we-would-rather-have-you-contribute-and-mess-something-up-than-not-contribute-so-please-go-ahead-and-mess-around-dash-sarah-mei&quot;&gt;“We would rather have you contribute and mess something up than not contribute. So please go ahead and mess around.” &amp;amp;dash; &lt;a href=&quot;http://twitter.com/SarahMei&quot; title=&quot;@SarahMei&quot;&gt;Sarah Mei&lt;/a&gt;&lt;/h2&gt;
  &lt;p&gt;Alright, here’s the latest. I’m going to start tossing out ideas for you to discuss, critique, scoff at and generally offer feedback on. I’m not looking for the “best way”, but I do love input. If you can fix anything or make some cool changes beyond the helpful hint, please submit a pull request. Take note though, in my &lt;a href=&quot;/Monoceros/2011/05/23/A-confession.html#tests&quot; title=&quot;A confession - Tests&quot;&gt;second post&lt;/a&gt; I mentioned that all pull requests have to include tests for code changes. Without further ado, my ideas.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;#1. Idea number the first: Branching&lt;/p&gt;

&lt;p&gt;I’m creating a few branches in &lt;a href=&quot;https://github.com/Spaceghost/Monoceros&quot; title=&quot;Monoceros@Github&quot;&gt;Monoceros&lt;/a&gt;. The first being “Web” where I’ll start with some cucumber view specs. This branch will deal directly with the web interface. I’m feeling out just how much cucumber I can handle with these view specs, I don’t want them to be too brittle, because if someone wants to step in and fiddle around to customise Monoceros for their application using the rake tasks I mentioned in my &lt;a href=&quot;/Monoceros/2011/05/22/Monoceros-beginning.html#rake&quot; title=&quot;Monoceros beginning - Rake tasks&quot;&gt;first post&lt;/a&gt; they’ll have a lot of failing features.&lt;/p&gt;

&lt;p&gt;I’m going to continue with this, creating branches for each part of Monoceros, such as “DSL” for the role defining DSL when I get there. Another for the dsl for views and so on.&lt;/p&gt;

&lt;p&gt;#2. Idea number the next one: Encouraging BDD &amp;amp; CT practices&lt;/p&gt;

&lt;p&gt;My good friend &lt;a href=&quot;https://github.com/workmad3&quot; title=&quot;Workmad3&quot;&gt;workmad3&lt;/a&gt; pointed out that my &lt;a href=&quot;https://github.com/Spaceghost/Monoceros/blob/72f72f3eb8743685921c67c0cc17383c38029b74/Gemfile&quot; title=&quot;Gemfile@Github&quot;&gt;Gemfile&lt;/a&gt; is silly, among other things. His reasoning is that I shouldn’t include &lt;a href=&quot;https://github.com/mynyml/watchr&quot; title=&quot;Watchr@Github&quot;&gt;Watchr&lt;/a&gt; and &lt;a href=&quot;https://github.com/seattlerb/zentest&quot; title=&quot;ZenTest@Github&quot;&gt;ZenTest&lt;/a&gt; inside my Gemfile. Those really do belong in a gemset, but it should be the choice of the developer if they do or do not want to use them. While this all made perfect sense, I was clever enough to state that I was including them to help build a community environment that embraced BDD and CT in their development (Read: Play) with Monoceros.&lt;/p&gt;

&lt;p&gt;Assuming the idea isn’t hated by too many, I’ll get the Gemfile in order and allow people to use –without when they bundle if they don’t want it. It’s like &lt;a href=&quot;http://rubygems.org/&quot;&gt;Rubygems&lt;/a&gt; not using a sensible default. &lt;strong&gt;cough&lt;/strong&gt;&lt;a href=&quot;https://github.com/rubygems/rubygems/pull/42&quot; title=&quot;Pull request number 42&quot;&gt;notgeneratingdocumentationbydefault&lt;/a&gt;&lt;strong&gt;cough&lt;/strong&gt; I also may be coming down with a cold.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;~/.gemrc&lt;/strong&gt;&lt;/p&gt;

&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;    --no-ri
    --no-rdoc
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;So, that’s that. I’m using cucumber and rspec right now. A great book to learn BDD and how to use these tools is the &lt;a href=&quot;http://pragprog.com/titles/achbd/the-rspec-book&quot; title=&quot;The RSpec Book @ Pragprog&quot;&gt;RSpec book&lt;/a&gt; by &lt;a href=&quot;https://github.com/dchelimsky&quot; title=&quot;dchelimsky@Github&quot;&gt;David Chelimsky&lt;/a&gt;. You can look at the Gemfile for the rest of the tools I use.&lt;/p&gt;

&lt;p&gt;I’m also going to be using &lt;a href=&quot;https://github.com/cucumber/aruba&quot; title=&quot;Aruba@Github&quot;&gt;aruba&lt;/a&gt; to test the monoceros executable for the generators and any other CLI goodness.&lt;/p&gt;

&lt;p&gt;#3 Concept the III: Those rails generate tasks&lt;/p&gt;

&lt;p&gt;&lt;a href=&quot;/Monoceros/2011/05/22/Monoceros-beginning.html#rake&quot; title=&quot;Monoceros beginning - Rake tasks&quot;&gt;Earlier&lt;/a&gt;, when I talked about Rake tasks, I mentioned three types of tasks. These are the generation commands for the engine itself. The &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;rails g monoceros:install:full&lt;/code&gt; task will fully install Monoceros into your application. Now it is easy to modify and customise.&lt;/p&gt;

&lt;p&gt;The &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;rails g monoceros:install:partial&lt;/code&gt; task is probably going to generate controllers and views for monoceros. Just in case all they want to change is the views and how they want to present data in the controller and the such. I’m thinking of having the files generate to their respective directories, and putting any images or assets that Monoceros uses in the proper directory.&lt;/p&gt;

&lt;p&gt;&lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;rails g monoceros:install:minimal&lt;/code&gt; will only generate the bare minimum of config files and whatever else it needs into your application. I’m expecting to include the usual opts for forcing it, not over-writing, etc.&lt;/p&gt;

&lt;p&gt;#4 Manifestation number four: Building usable and cogent DSL’s for Monoceros&lt;/p&gt;

&lt;p&gt;There will be two [DSL][]’s in Monoceros. The first is the Roles DSL. The goal with this DSL is to be as expressive as possible, but easy to use with the web panel. Since I’m going to be using it for storing Roles and the such, I need to make the web panel work with it, loading and saving to the config in that DSL. This I might need a bit of help on.&lt;/p&gt;

&lt;p&gt;The second DSL is the for the view. I’d love to work with developers who know what they’d like to see in this DSL. My goal is to build a DSL that’s fun to use and easy to manage. I already got some feedback from a few good friends working on the &lt;a href=&quot;http://rubunity.com/&quot; title=&quot;Rubunity&quot;&gt;Rubunity&lt;/a&gt; web application and community. Here’s what one of the guys there suggested for passing blocks with roles (In Haml). &lt;script src=&quot;https://gist.github.com/958822.js?file=show.html.haml&quot;&gt; &lt;/script&gt;&lt;/p&gt;

&lt;p&gt;Won’t you be my neighbor? Comment, discuss and let me know what your thoughts are, or questions. If the question is one I think would deserve a blogpost, I’ll write one on your question.&lt;/p&gt;

&lt;p&gt;[DSL]: http://en.wikipedia.org/wiki/Domain-specific_language “DSL@Wikipedia&lt;/p&gt;

</content>
 </entry>
 
 <entry>
   <title>A confession</title>
   <link href="http://spacegho.st/A-confession"/>
   <updated>2011-05-23T00:00:00+00:00</updated>
   <id>http://Spacegho.st/A-confession</id>
   <content type="html">&lt;p&gt;&lt;a href=&quot;/Monoceros/2011/05/22/Monoceros-beginning.html&quot; title=&quot;Monoceros-beginning&quot;&gt;Yesterday&lt;/a&gt; was a productive day. I feel so good about it, I even broke down a wall that I’ve had for a long time.
For the first time in Spaceghost history, I open sourced a project before it was even fit for human consumption.&lt;/p&gt;

&lt;p&gt;Why would this matter in the least? To quote an old adage, “Commit early, commit often”.
I’m usually pretty good at keeping to my deadlines.
But when I start a project that belongs solely to me, I tend to let it flounder after a while.&lt;/p&gt;

&lt;p&gt;Now that I’ve given a small backstory to the confession, I’ll spill the beans.
I started &lt;a href=&quot;https://github.com/Spaceghost/Monoceros&quot; title=&quot;Monoceros@Github&quot;&gt;Monoceros&lt;/a&gt; a couple weeks ago. Oh those were the days.
I was hacking along, making great progress and really just exploding out onto the repository with code.
What deterred me from this path was an unwelcome guest. Or rather, quite a few.
Since I tossed testing to the wayside in order to fully express myself, I introduced a large gaping hole into my project.
Things were breaking left and right.
You might say, “That’s not a problem, just track down your bugs.” and I agree with you, you should track down bugs.
But when those bugs exist purely because you failed to keep code that you’ve already written working, that becomes an issue for me.&lt;/p&gt;

&lt;p&gt;I still have the code I wrote in haste. It has a working dashboard panel and automagically detects the models in your application.
Although I couldn’t quite get it to work with models in engines.
I learned a lot from the time I spent employing as many metaprogramming spells as I could wield, and properly namespacing my engine by hand.
I was so silly, I even wrote it inside a plain rails application! Not a shiny new rails 3.1 engine. How ignorant I was!&lt;/p&gt;

&lt;p&gt;Long story short (tl;dr), that code won’t ever be open sourced and I will never release something meant to help the Ruby on Rails community without &lt;a name=&quot;tests&quot;&gt; &lt;/a&gt;tests to ensure that it works.
This is just as much a promise to you as it is a promise to me.
If you find that I’m lacking, please let me know. I’ll also not accept code without tests.
If you would like help testing your code, you should either be BDD’ing it along with me and whomever is playing with Monoceros, or you should make friends and get some help with your tests.&lt;/p&gt;

&lt;p&gt;After some careful thought, I decided that giving &lt;a href=&quot;https://github.com/Spaceghost/Monoceros&quot; title=&quot;Monoceros@Github&quot;&gt;Monoceros&lt;/a&gt; to you was the best course of action (Woo presents!).
I’ll be working on it, but this is for you. This is for everyone. This isn’t about me.&lt;/p&gt;

&lt;p&gt;Thank you for being my silent partner in crime,&lt;/p&gt;

&lt;p&gt;~Johnneylee&lt;/p&gt;

</content>
 </entry>
 
 <entry>
   <title>Monoceros beginning</title>
   <link href="http://spacegho.st/Monoceros-beginning"/>
   <updated>2011-05-22T00:00:00+00:00</updated>
   <id>http://Spacegho.st/Monoceros-beginning</id>
   <content type="html">&lt;p&gt;It’s 6 am.&lt;/p&gt;

&lt;p&gt;So here is where I start my journey. Right now, I’m sitting in my living room, listening to the menu music from a movie that’s been playing for hours on end on my media center computer.&lt;/p&gt;

&lt;p&gt;Perhaps you’ve been there. Furious coding, stopping to fix some errant code (Not mine. I swear) and then mashing away at your keyboard in attempt to pick up the slack and get that velocity back. All the while, the movie you started to ‘watch’ has been left on, desperate for your attention.&lt;/p&gt;

&lt;p&gt;Again I say, here is where I start my journey. Working with edge &lt;a href=&quot;https://github.com/rails/rails&quot; title=&quot;Rails@Github&quot;&gt;Rails&lt;/a&gt;, fresh from the github repository. &lt;a href=&quot;http://twitter.com/dhh&quot; title=&quot;@dhh&quot;&gt;@dhh&lt;/a&gt; has just pushed the bump for the rails 3.1 release candidate moments before I start the long-winded bundle install that will be the first step towards building a better and brighter rails future. What’s the target, you ask? &lt;a href=&quot;https://github.com/Spaceghost/Monoceros&quot; title=&quot;Monoceros@Github&quot;&gt;Monoceros&lt;/a&gt;. The name means &lt;a href=&quot;http://en.wikipedia.org/wiki/Monoceros&quot; title=&quot;Monoceros@Wikipedia&quot;&gt;Unicorn&lt;/a&gt; in &lt;span class=&quot;strike&quot;&gt;geek&lt;/span&gt;^W Greek. What Monoceros does (will do), would be best explained in parts.&lt;/p&gt;

&lt;ol&gt;
  &lt;li&gt;
    &lt;p&gt;Engine&lt;/p&gt;

    &lt;p&gt;Monoceros is first and foremost a Rails 3.1 engine. That is to say, a mountable application for your rails 3.1 applications.
 My philosophy about engines is that they should be easy to use and easy to customize. When I arrive at the point where Monoceros  works reasonably as intended, I will be including rails generators for different types of installations of the engine should you want to modify anything.&lt;/p&gt;

    &lt;ul&gt;
      &lt;li&gt;
        &lt;p&gt;&lt;span id=&quot;rake&quot;&gt;Full&lt;/span&gt; install - Completely installing the engine inside your application. This is meant for those who want to drastically modify Monoceros in their application.&lt;/p&gt;
      &lt;/li&gt;
      &lt;li&gt;
        &lt;p&gt;Partial install - I’m thinking, probably views, maybe some controllers, this will have to be explored more. I’ll make a note to let you know what I come up with.&lt;/p&gt;
      &lt;/li&gt;
      &lt;li&gt;
        &lt;p&gt;Minimal install - Should there be anything that simply &lt;em&gt;must&lt;/em&gt; be generated for you, this will likely be the generator it will go in.&lt;/p&gt;
      &lt;/li&gt;
    &lt;/ul&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;Authentication&lt;/p&gt;

    &lt;p&gt;I’m going to include authentication into the engine. Why? Because I can, it takes so little time to actually code, and if I’m clever enough, I’m going to make it work with your whole application if you let me. I’m thinking it’ll be held in a config file, you can specify the options for with &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;rails g monoceros:install:minimal&lt;/code&gt;. The goal is to have this be a fallback, and have Monoceros (That clever bastard™) check for &lt;a href=&quot;https://github.com/plataformatec/devise&quot; title=&quot;Devise@Github&quot;&gt;Devise&lt;/a&gt; and maybe other authentication gems and use those as a priority. Sounds nifty, right?&lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;Authorization&lt;/p&gt;

    &lt;p&gt;Now here’s the big one folks. This is the word that I have dreaded in every rails application, nay, every application I have ever made. Basically, I’m going to attempt to have authorization on both model and controller levels. Some prefer one over the other, some prefer both, and God save the ones who prefer none at all. (Totally kidding, applications without permissions are cool too.)&lt;/p&gt;

    &lt;p&gt;To start, Monceros is going to be dependent on Active Record. But don’t let that fool you, my goal is to be completely database agnostic in a future release. Yes, the ability to drop this little gem into your Gemfile and use it with any rails application is possible. I hate hard work, so I might enlist some of my friends to help me with achieving that goal. But anyways, it’s going to be dependent on Active Record, and pull some witty tricks through the magic of metaprogramming to grab all your tables and your controllers and (hopefully) present a nice interface for you to start working with.&lt;/p&gt;

    &lt;p&gt;When you arrive at your monoceros dashboard, you’ll be able to start defining roles. These roles consist of permissions on controllers and models. I’m going to start with controllers since that’s what most people get all giddy for anyways, and they seem the easiest to implement. After you define a role, you would select which table(s) contain users. You can then select one or more users and give them one of the roles you made.&lt;/p&gt;

    &lt;p&gt;Along these lines, I’ve been tossing around the idea of groups, which is kind of like a role, except it doesn’t have any specific permissions applied yet. Logic will get the better of me and reveal the best approach later. Long live Agile. (Best cop out for not having any idea what the plan is to date)&lt;/p&gt;
  &lt;/li&gt;
&lt;/ol&gt;

</content>
 </entry>
 

</feed>

