Skip to content

Commit

Permalink
Messages: use tar for macOS and Linux
Browse files Browse the repository at this point in the history
  • Loading branch information
PMeira committed Jul 13, 2022
1 parent df15ba4 commit 7daaf4c
Showing 1 changed file with 14 additions and 3 deletions.
17 changes: 14 additions & 3 deletions deps/build.jl
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,18 @@ function download(::Type{Linux})
println("Success")
end

function download_messages(::Union{Type{Linux}, Type{MacOS}})
url = "https://github.com/dss-extensions/dss_capi/releases/download/$(DSS_CAPI_TAG)/messages.tar.gz"
@show url
filename = normpath(joinpath(@__DIR__, "messages.tar.gz"))
Base.download(url, filename)

directory = normpath(@__DIR__)
run(`tar -xvf $filename -C $directory`)
rm(joinpath(@__DIR__, "messages.tar.gz"), force=true)
println("Success")
end

function download(::Type{Windows})

if typeof(1) === Int64
Expand Down Expand Up @@ -90,8 +102,7 @@ function download(::Type{Windows})
println("Success")
end

function download_messages()

function download_messages(::Type{Windows})
url = "https://github.com/dss-extensions/dss_capi/releases/download/$(DSS_CAPI_TAG)/messages.zip"
@show url
filename = normpath(joinpath(@__DIR__, "messages.zip"))
Expand Down Expand Up @@ -122,4 +133,4 @@ else
end

download(os)
download_messages()
download_messages(os)

0 comments on commit 7daaf4c

Please sign in to comment.