From 6f94747ebda33f9bdd6325faa3efa8854c815f8d Mon Sep 17 00:00:00 2001 From: Amir Yalon Date: Mon, 4 Apr 2011 18:04:39 +0300 Subject: [PATCH] Fix documentation for Capistrano with different environments --- README.md | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/README.md b/README.md index 5ae6ec2..addc176 100644 --- a/README.md +++ b/README.md @@ -95,6 +95,13 @@ For example, if you're using bundler do this: set :whenever_command, "bundle exec whenever" require "whenever/capistrano" +If you are using different environments (such as staging, production), then you may want to do this: + + set :whenever_environment, defer { stage } + require "whenever/capistrano" + +The capistrano variable `:stage` should be the one holding your environment name. This will make the correct `:environment` available in your schedule.rb. + ### The `whenever` command $ cd /my/rails/app