Skip to content

Instantly share code, notes, and snippets.

@farcaller
Created May 28, 2012 20:50
Show Gist options
  • Save farcaller/2821170 to your computer and use it in GitHub Desktop.
Save farcaller/2821170 to your computer and use it in GitHub Desktop.
From 520d5d472d5e13ef1f68c732a748307db753fece Mon Sep 17 00:00:00 2001
From: Vladimir Pouzanov <farcaller@gmail.com>
Date: Mon, 28 May 2012 23:24:51 +0300
Subject: [PATCH] Resolve gem name internally
---
gem/specification.rb | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/gem/specification.rb b/gem/specification.rb
index 655709b..d4140b8 100644
--- a/gem/specification.rb
+++ b/gem/specification.rb
@@ -1,10 +1,10 @@
module Gem
class Specification
- def motion(name)
+ def motion
spec = Motion::Gem::MotionSpec.new
yield spec
- Motion::Gem::Manager.instance.specs[name] = spec
+ Motion::Gem::Manager.instance.specs[self.name] = spec
end
end
end
--
1.7.8
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment