Browse files

specifying counters directory via COUNTERS_DIR env var

  • Loading branch information...
1 parent b8b29ac commit 5d010fe416f9f37b4de3bab465adb57d4e2855cc @sickill committed Mar 22, 2009
Showing with 2 additions and 2 deletions.
  1. +2 −2 sickounter.rb
View
4 sickounter.rb
@@ -1,7 +1,7 @@
require 'rubygems'
require 'sinatra'
-COUNTERS_DIR = ARGV[0] || File.join(File.dirname(__FILE__), 'counters')
+COUNTERS_DIR = ENV['COUNTERS_DIR'] || File.join(File.dirname(__FILE__), 'counters')
get '/' do
url = params[:f] or raise Sinatra::NotFound
@@ -64,4 +64,4 @@
<body>
<%= yield %>
</body>
-</html>
+</html>

0 comments on commit 5d010fe

Please sign in to comment.