Skip to content

Commit a163bc2

Browse files
authored
Update new_versions.jl
1 parent 2a6edb3 commit a163bc2

File tree

1 file changed

+11
-2
lines changed

1 file changed

+11
-2
lines changed

src/utilities/new_versions.jl

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -289,7 +289,7 @@ function make_pr_for_new_version(
289289

290290
options.cc_user && cc_mention_user(forge, repo, new_pr; env=env)
291291
options.unsub_from_prs && unsub_from_pr(forge, new_pr)
292-
force_ci_trigger(forge, new_pr_title, new_branch_name, pkey_filename; env=env)
292+
force_ci_trigger(forge, ci_cfg, repo, new_pr_title, new_branch_name, pkey_filename; env=env)
293293

294294
# Return to the master branch
295295
git_checkout(master_branch_name)
@@ -301,8 +301,15 @@ function make_pr_for_new_version(
301301
return created_pr
302302
end
303303

304+
function git_push(
305+
forge::Forge,
306+
GitHubActions,
307+
repo::GitHub.Repo,
308+
304309
function force_ci_trigger(
305310
api::GitLab.GitLabAPI,
311+
ci_cfg::CIService,
312+
repo::GitLab.Project
306313
pr_title::AbstractString,
307314
branch_name::AbstractString,
308315
pkey_filename::Union{AbstractString,Nothing};
@@ -314,6 +321,8 @@ end
314321

315322
function force_ci_trigger(
316323
api::GitHub.GitHubAPI,
324+
ci_cfg::CIService,
325+
repo::GitHub.Repo
317326
pr_title::AbstractString,
318327
branch_name::AbstractString,
319328
pkey_filename::Union{AbstractString,Nothing};
@@ -337,7 +346,7 @@ function force_ci_trigger(
337346
# Force push the changes to trigger the PR
338347
api_retry() do
339348
@debug "force_ci_trigger: force-pushing the changes to trigger CI on the PR"
340-
@mock git_push("origin", branch_name, pkey_filename; force=true, env=env)
349+
@mock git_push(api, ci_cfg, repo, "origin", branch_name, pkey_filename; force=true, env=env)
341350
end
342351
end
343352

0 commit comments

Comments
 (0)