This project is archived and is in readonly mode.
GitHub :author param to config.gem (Rails::GemDependency)
-
José Valim
I've seen a similar patch about this around. If I'm sure it used config.gem 'gem', :github => 'author', but I like more yours. +1
-
Jordi Bunster
José:
I did a quick search for the one you mentioned but I couldn't find it here on Lighthouse. Is it here, do you know?
-
ronin-278 (at lighthouseapp)
I would go with something like
:github_author => 'foobar'. More explicit IMO. -
Pratik
- State changed from new to wontfix
- Title changed from [PATCH] GitHub :author param to config.gem (Rails::GemDependency) to GitHub :author param to config.gem (Rails::GemDependency)
Not sure I like the idea of having a service specific code in Rails. If it's in rubygems, that's cool.
Will reopen if more ppl think otherwise.
Thanks.
-
Jordi Bunster
Nicolás: yeah, I went for brevity, but I see your point. I wouldn't mind changing the syntax.
Pratik: I thought about it, but the reality is that more and more people publish on GitHub only, which at the end of the day, is just service, not unlike RubyForge.
-
Damian Janowski
What about a
:prependoption?config.gem 'will_paginate', :prepend => 'mislav'
That way it's not service-specific.
-
Jordi Bunster
Damian:
I think the service-specific part is the fact that when you pass :author (or :prepend or :whatever_color_the_shed_is) we then assume :source => GitHub.
-
Pratik
Hey Jordi,
I really don't have a strong opinion about this. Will reopen if more people on the mailing list think this is a good feature. Please don't take "wontfix" the wrong way, just trying to do some LH gardening :)
Thanks.
-
Jordi Bunster
Pratik: I know. I don't take it one way or another. Just trying to get the patch in. :P
-
Jordi Bunster
This is a workaround to now having this in Rails: http://gist.github.com/78259
Sadly, I can't really make it a plugin, because of how early in the initialization it has to work.
-
Markús
@Jordi
I've started a ticket for something similar about one month ago, it's may be the one José Valim is talking about.
There's an interesting answer by Matt Jones in my ticket about this concern. It's practically the same Pratik says in his comment, and I agree with them, perhaps it's better to leave the config.gem as it is right now (it makes sense since it's planned to make Rails as agnostic as possible in Rails 3).
And think, we already have templates which make a lot of automatic work for us. For example, I've created a "templates_helper" with functions like this "github_gems" to easily add and remove gems from templates both for new or existing applications.
By the way. I like your approach, it's more clear than mine.
Cheers. Markus.
