Skip to content

Commit

Permalink
Add a skip for GITHUB_ACTIONS (#277)
Browse files Browse the repository at this point in the history
  • Loading branch information
odow authored Dec 4, 2019
1 parent c8d9f17 commit b1dcd1f
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 1 deletion.
10 changes: 9 additions & 1 deletion deps/build.jl
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
if haskey(ENV, "GITHUB_ACTIONS")
# We're being run as part of a Github action. The most likely case is that
# this is the auto-merge action as part of the General registry.
# For now, skip the installation.
@info("Detected a Github action. Skipping installation.")
exit(0)
end

using Libdl

const DEPS_FILE = joinpath(@__DIR__, "deps.jl")
Expand Down Expand Up @@ -128,7 +136,7 @@ function diagnose_gurobi_install()
println("""
We could not find a version of Gurobi in your path, and we could
not find the environment variable `GUROBI_HOME`. You should set
not find the environment variable `GUROBI_HOME`. You should set
the `GUROBI_HOME` environment variable to point to the install
location. For example:
- on Windows, this might be `C:\\Program Files\\gurobi810\\win64\\`
Expand Down
8 changes: 8 additions & 0 deletions test/runtests.jl
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
if haskey(ENV, "GITHUB_ACTIONS")
# We're being run as part of a Github action. The most likely case is that
# this is the auto-merge action as part of the General registry.
# For now, we're going to silently skip the tests.
@info("Detected a Github action. Skipping tests.")
exit(0)
end

using Gurobi, Test, Random

@testset "C API" begin
Expand Down

2 comments on commit b1dcd1f

@odow
Copy link
Member Author

@odow odow commented on b1dcd1f Dec 4, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@JuliaRegistrator register()

@JuliaRegistrator
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Registration pull request created: JuliaRegistries/General/6257

After the above pull request is merged, it is recommended that a tag is created on this repository for the registered package version.

This will be done automatically if Julia TagBot is installed, or can be done manually through the github interface, or via:

git tag -a v0.7.4 -m "<description of version>" b1dcd1f57242064ad504bef7e4bbaa6c6ea4ae04
git push origin v0.7.4

Please sign in to comment.