powder-rb / powder

Makes Pow even easier. I mean really, really, ridiculously easy
http://git.io/powder
MIT License
1.29k stars 69 forks source link

config.ru for Rails 2.3 applications #89

Closed nickhammond closed 11 years ago

nickhammond commented 11 years ago

I know this probably isn't too common anymore but I'm working on an older application for a client and this popped up.

$ powder link
This appears to be a Rails 2 application. You need a config.ru file.
Do you want to autogenerate a basic config.ru for Rails 2? y
      create  config.ru
Your application is now available at http://example.dev/

The config.ru file that it generated contained:

<html><body>You are being <a href="https://github.com/gist/909308">redirected</a>.</body></html>

I haven't looked into it but it looks like the gist that powder typically looks for no longer exists. I ended up just finding this gist which works fine https://gist.github.com/jlindley/925704

Powder 0.2.0, REE.

rodreegez commented 11 years ago

Hey, thanks for the report.

I think the line that is causing you grief is: https://github.com/rodreegez/powder/blob/master/bin/powder#L458

If you'd like to take a stab at a pull request I'm sure we'd all be pleased!

nickhammond commented 11 years ago

Actually, it looks like the latest commit on master addresses the issue. https://github.com/rodreegez/powder/commit/96af4fae93bd35a47a6cf0baa99f85aa739d0835

I'll close this issue.

thomasklemm commented 11 years ago

@rodreegez The gist urls changed. https://github.com/rodreegez/powder/commit/96af4fae93bd35a47a6cf0baa99f85aa739d0835 should fix this issue.

nickhammond commented 11 years ago

Since the gist is only two lines of code, why don't we just update it to have the contents of the gist? If not, then maybe we should use get_gist() to grab the gist.

I noticed there's get_gist() but that's only being used by check_rdebug_initializer. The contents of get_gist() contain the same gist downloading code that's in is_powable?.

thomasklemm commented 11 years ago

@nickhammond Nice catch, I've opened a PR to remove this duplication.