From 39769ea99778dfbb46eb7b17389819c8ebabe9f5 Mon Sep 17 00:00:00 2001 From: Chris Dodge Date: Mon, 14 Jan 2013 22:51:56 -0500 Subject: [PATCH] allow for optional 'COURSE_DIR' parameter for the import rake target so that we can import only a single course --- rakefile | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/rakefile b/rakefile index e984b7cc5b..b8873b961f 100644 --- a/rakefile +++ b/rakefile @@ -421,7 +421,9 @@ end namespace :cms do desc "Import course data within the given DATA_DIR variable" task :import do - if ENV['DATA_DIR'] + if ENV['DATA_DIR'] and ENV['COURSE_DIR'] + sh(django_admin(:cms, :dev, :import, ENV['DATA_DIR'], ENV['COURSE_DIR'])) + elsif ENV['DATA_DIR'] sh(django_admin(:cms, :dev, :import, ENV['DATA_DIR'])) else raise "Please specify a DATA_DIR variable that point to your data directory.\n" +