[Groonga-commit] groonga/heroku-sample-rroonga-blog at 7e493f2 [master] Use web_url because it can be set by heroku apps:info

Back to archive index

Kouhei Sutou null+****@clear*****
Sun May 25 19:18:30 JST 2014


Kouhei Sutou	2014-05-25 19:18:30 +0900 (Sun, 25 May 2014)

  New Revision: 7e493f28d999fa20a94a24bc55aae014555af751
  https://github.com/groonga/heroku-sample-rroonga-blog/commit/7e493f28d999fa20a94a24bc55aae014555af751

  Message:
    Use web_url because it can be set by heroku apps:info

  Modified files:
    lib/tasks/import.rake

  Modified: lib/tasks/import.rake (+5 -4)
===================================================================
--- lib/tasks/import.rake    2014-05-25 19:09:57 +0900 (25584bc)
+++ lib/tasks/import.rake    2014-05-25 19:18:30 +0900 (5a46dc5)
@@ -1,5 +1,5 @@
 def import_rss(url)
-  uri = URI(ENV['APP_URL'])
+  uri = URI(ENV['web_url'])
   uri.path = '/posts/new'
   agent = Mechanize.new
 
@@ -18,10 +18,11 @@ namespace :import do
     require 'rss'
     require 'mechanize'
 
-    if ENV['APP_URL'].nil?
+    if ENV['web_url'].nil?
       message = <<-MESSAGE
-Must set APP_URL environment variable
-e.g.: rake import APP_URL=http://localhost:3000
+Must set web_url environment variable
+e.g.: rake import web_url=http://localhost:3000
+e.g.: rake import $(heroku apps:info --shell | grep '^web_url=')
       MESSAGE
       raise message
     end
-------------- next part --------------
HTML����������������������������...
下載 



More information about the Groonga-commit mailing list
Back to archive index