Skip to content
This repository has been archived by the owner on Apr 3, 2021. It is now read-only.

Commit

Permalink
Fixed several issues with the build.jl script and add `Pkg.build("Pla…
Browse files Browse the repository at this point in the history
…yground")` to .travis.yml.

* Fix doesn't support the '_' environment variable used to get the julia path so we
  resort to calling which julia if '_' isn't set.
* Logging.jl currently has an [issue](kmsquire/Logging.jl#28) where
  it will segfault writing to an invalid TTY occasionally (mostly due to a precompiled reference to STDOUT).
  • Loading branch information
rofinn committed Dec 7, 2015
1 parent 5349175 commit 715575b
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ notifications:
email: false
script:
- if [[ -a .git/shallow ]]; then git fetch --unshallow; fi
- julia --depwarn=no -e 'Pkg.init(); Pkg.clone(pwd()); Pkg.clone("https://github.com/invenia/Mocking.jl"); Pkg.test("Playground"; coverage=true)'
- julia --depwarn=no -e 'Pkg.init(); Pkg.clone(pwd()); Pkg.build("Playground"); Pkg.clone("https://github.com/invenia/Mocking.jl"); Pkg.test("Playground"; coverage=true)'
after_success:
- julia -e 'cd(Pkg.dir("Playground")); Pkg.add("Coverage"); using Coverage; Codecov.submit(process_folder())'
- julia -e 'cd(Pkg.dir("Playground")); Pkg.add("Coverage"); using Coverage; Coveralls.submit(process_folder())'
14 changes: 11 additions & 3 deletions deps/build.jl
Original file line number Diff line number Diff line change
@@ -1,10 +1,18 @@
using Logging

Logging.configure(level=Logging.INFO)
Logging.configure(output=STDOUT, level=Logging.INFO)

BUILDFILE_PATH = @__FILE__
DEPS_PATH = dirname(BUILDFILE_PATH)
JULIA_PATH = ENV["_"]
JULIA_PATH = "#!/usr/bin/env julia"

if haskey(ENV, "_")
JULIA_PATH = ENV["_"]
else
try
JULIA_PATH = strip(readall(`which julia`))
end
end

include(joinpath(DEPS_PATH, "../src/Playground.jl"))

Expand Down Expand Up @@ -38,7 +46,7 @@ end
#=
Dynamically set the shebang in the playground script.
This is necessary for several reasons:
1. /usr/bin/env will stall if we want to include the `--depwarn=noe`
1. /usr/bin/env will stall if we want to include the `--depwarn=no`
2. people may have their default julia version installed in weird locations
3. chances are that people will want playground to use the same julia environment that they installed it from.
=#
Expand Down

0 comments on commit 715575b

Please sign in to comment.