Skip to content

Commit 1d05820

Browse files
committed
[py] Remove unused virtual environment handling from crazy-fun
1 parent ac158e0 commit 1d05820

File tree

1 file changed

+0
-28
lines changed

1 file changed

+0
-28
lines changed

rake-tasks/crazy_fun/mappings/python.rb

Lines changed: 0 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,6 @@ def add_all(fun)
99
fun.add_mapping("py_test", Python::AddDependencies.new)
1010
fun.add_mapping("py_test", Python::RunTests.new)
1111

12-
fun.add_mapping("py_env", Python::VirtualEnv.new)
13-
1412
fun.add_mapping("py_docs", Python::GenerateDocs.new)
1513

1614
fun.add_mapping("py_install", Python::Install.new)
@@ -82,32 +80,6 @@ def handle(fun, dir, args)
8280
end
8381
end
8482

85-
class VirtualEnv
86-
def handle(fun, dir, args)
87-
task Tasks.new.task_name(dir, args[:name]) do
88-
dest = Platform.path_for(args[:dest])
89-
pip_pkg = "pip install #{args[:packages].join(' ')}"
90-
virtualenv = ["virtualenv", "--no-site-packages", " #{dest}"]
91-
virtualenv += ["-p", ENV['pyversion']] if ENV['pyversion']
92-
sh virtualenv.join(' '), :verbose => true do |ok, res|
93-
unless ok
94-
puts ""
95-
puts "PYTHON DEPENDENCY ERROR: Virtualenv not found."
96-
puts "Please run '[sudo] pip install virtualenv'"
97-
puts ""
98-
end
99-
end
100-
101-
slash = Platform.dir_separator
102-
python_dir = dest + slash + (windows? ? "Scripts" : "bin")
103-
pip_install = python_dir + slash + pip_pkg
104-
sh pip_install, :verbose => true
105-
106-
sh "#{python_dir}#{slash}python setup.py install", :verbose => true
107-
end
108-
end
109-
end
110-
11183
class GenerateDocs < Tasks
11284
def handle(fun, dir, args)
11385
task Tasks.new.task_name(dir, args[:name]) do

0 commit comments

Comments
 (0)