Skip to content

Commit

Permalink
Use PyCall.conda_add to install dependencies in deps/build.jl
Browse files Browse the repository at this point in the history
  • Loading branch information
tkf committed Nov 8, 2018
1 parent 8803d49 commit fcb0e91
Showing 1 changed file with 27 additions and 0 deletions.
27 changes: 27 additions & 0 deletions deps/build.jl
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
in_CI = lowercase(get(ENV, "CI", "false")) == "true"

if in_CI
# Let PyCall.jl use Python interpreter from Conda.jl
# See: https://github.com/JuliaPy/PyCall.jl
ENV["PYTHON"] = ""
Pkg.build("PyCall")
end

using PyCall

packages = ["ipython"]
if in_CI
push!(packages, "pytest")
if get(ENV, "CONDA_JL_VERSION", "") == "2"
# For IPython.testing.globalipapp
push!(packages, "mock")
end
end
PyCall.conda_add(packages)

if VERSION >= v"0.7.0-"
@info "PyCall/deps/build.log:"
print(read(
joinpath(dirname(dirname(pathof(IPython.PyCall))), "deps", "build.log"),
String))
end

0 comments on commit fcb0e91

Please sign in to comment.