Skip to content

Commit

Permalink
[DEBUG] Try to git reset. Scary times
Browse files Browse the repository at this point in the history
  • Loading branch information
abelsiqueira committed May 24, 2024
1 parent 1193947 commit 9aa1d4e
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions test/runtests.jl
Original file line number Diff line number Diff line change
Expand Up @@ -36,17 +36,20 @@ template_options = Dict(
@info "git commands"
run(`git status`)
run(`git diff`)
if get(ENV, "CI", "nothing") == "true"
run(`git reset --hard HEAD`)
end

template_path = joinpath(@__DIR__, "..")

cd(tmpdir1) do
COPIERTemplate.generate("."; data = template_options)
COPIERTemplate.generate("."; data = template_options, vcs_ref = "HEAD")
end

bash_args = vcat([["-d"; "$k=$v"] for (k, v) in template_options]...)

cd(tmpdir2) do
run(`copier copy $bash_args $template_path .`)
run(`copier copy --vcs-ref HEAD $bash_args $template_path .`)
end

ignore(line) = startswith("_commit")(line) || startswith("_src_path")(line)
Expand Down

0 comments on commit 9aa1d4e

Please sign in to comment.