diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 237641963..99810d8a4 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -92,8 +92,8 @@ jobs: - name: Test downstream packages if: startsWith(matrix.os, 'ubuntu') run: | - xvfb-run julia --color=yes ci/downstream.jl GraphRecipes || true - xvfb-run julia --color=yes ci/downstream.jl StatsPlots || true + xvfb-run julia --color=yes ci/downstream.jl GraphRecipes + xvfb-run julia --color=yes ci/downstream.jl StatsPlots - uses: julia-actions/julia-processcoverage@latest if: startsWith(matrix.os, 'ubuntu') diff --git a/ci/downstream.jl b/ci/downstream.jl index 070dd9033..02b3c9d36 100644 --- a/ci/downstream.jl +++ b/ci/downstream.jl @@ -3,11 +3,11 @@ using Pkg const LibGit2 = Pkg.GitTools.LibGit2 const TOML = Pkg.TOML -failsafe_clone_checkout(path, url) = begin +failsafe_clone_checkout(path, url; branch="master", stable=true) = begin local repo for i in 1:6 try - repo = Pkg.GitTools.ensure_clone(stdout, path, url) + repo = Pkg.GitTools.ensure_clone(stdout, path, url; branch) break catch err @warn err @@ -27,11 +27,14 @@ failsafe_clone_checkout(path, url) = begin end @assert isfile(versions) - version_dict = TOML.parse(read(versions, String)) - stable = VersionNumber.(keys(version_dict)) |> maximum - tag = LibGit2.GitObject(repo, "v$stable") - hash = string(LibGit2.target(tag)) - LibGit2.checkout!(repo, hash) + if stable + version_dict = TOML.parse(read(versions, String)) + stable = VersionNumber.(keys(version_dict)) |> maximum + tag = LibGit2.GitObject(repo, "v$stable") + hash = string(LibGit2.target(tag)) + LibGit2.checkout!(repo, hash) + else + end nothing end @@ -65,7 +68,11 @@ test_stable(pkg::AbstractString) = begin end pkg_dir = joinpath(tmpd, "$pkg.jl") - failsafe_clone_checkout(pkg_dir, "https://github.com/JuliaPlots/$pkg.jl") + if true # v2, remove when stable + failsafe_clone_checkout(pkg_dir, "https://github.com/JuliaPlots/$pkg.jl"; branch="v2", stable=false) + else + failsafe_clone_checkout(pkg_dir, "https://github.com/JuliaPlots/$pkg.jl") + end fake_supported_versions!(pkg_dir) Pkg.develop(; path = pkg_dir) diff --git a/docs/ci_build.sh b/docs/ci_build.sh index 7104249a2..ae704213d 100644 --- a/docs/ci_build.sh +++ b/docs/ci_build.sh @@ -54,10 +54,7 @@ export JULIA_CONDAPKG_BACKEND=MicroMamba julia='xvfb-run -a julia --color=yes --project=docs' -# $julia -e 'using Pkg; Pkg.add(PackageSpec(url="https://github.com/JuliaPlots/Plots.jl", rev=split(ENV["GITHUB_REF"], "/", limit=3)[3], subdir="RecipesBase"));' #FIXME: not needed when registered -# $julia -e 'using Pkg; Pkg.add(PackageSpec(url="https://github.com/JuliaPlots/Plots.jl", rev=split(ENV["GITHUB_REF"], "/", limit=3)[3], subdir="RecipesPipeline"));' #FIXME: not needed when registered -# $julia -e 'using Pkg; Pkg.add(PackageSpec(url="https://github.com/JuliaPlots/Plots.jl", rev=split(ENV["GITHUB_REF"], "/", limit=3)[3], subdir="PlotsBase"));' #FIXME: not needed when registered -$julia -e 'using Pkg; Pkg.develop([(;path="."), (;path="./RecipesBase"), (;path="./RecipesPipeline"), (;path="./PlotsBase")]);' #FIXME: not needed when registered +$julia -e 'using Pkg; Pkg.develop([(; path="."), (; path="./RecipesBase"), (; path="./RecipesPipeline"), (; path="./PlotsBase")]);' # FIXME: not needed when registered $julia -e ' using Pkg; Pkg.add("CondaPkg") using CondaPkg; CondaPkg.resolve() @@ -79,6 +76,9 @@ $julia -e ' CondaPkg.status() ' +$julia -e 'using Pkg; Pkg.add(PackageSpec(name="StatsPlots", rev="v2"))' # FIXME: remove when StatsPlots v2 is out +$julia -e 'using Pkg; Pkg.add(PackageSpec(name="GraphRecipes", rev="v2"))' # FIXME: remove when StatsPlots v2 is out + echo "== build documentation for $GITHUB_REPOSITORY@$GITHUB_REF, triggered by $GITHUB_ACTOR on $GITHUB_EVENT_NAME ==" if [ "$GITHUB_REPOSITORY" == 'JuliaPlots/PlotDocs.jl' ]; then $julia -e 'using Pkg; Pkg.add(PackageSpec(name="Plots", rev="master"))'