Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
renovate
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Model registry
Analyze
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
GitHub Mirror
Renovate Bot
renovate
Commits
d03b7e61
Commit
d03b7e61
authored
4 years ago
by
Rhys Arkins
Browse files
Options
Downloads
Patches
Plain Diff
fix: deduct pr remaining when automerging comment
Closes #6266
parent
32725d23
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
lib/workers/repository/process/write.ts
+14
-1
14 additions, 1 deletion
lib/workers/repository/process/write.ts
with
14 additions
and
1 deletion
lib/workers/repository/process/write.ts
+
14
−
1
View file @
d03b7e61
...
@@ -28,6 +28,7 @@ export async function writeUpdates(
...
@@ -28,6 +28,7 @@ export async function writeUpdates(
return
true
;
return
true
;
});
});
let
prsRemaining
=
await
getPrsRemaining
(
config
,
branches
);
let
prsRemaining
=
await
getPrsRemaining
(
config
,
branches
);
logger
.
debug
({
prsRemaining
},
'
Calculated maximum PRs remaining this run
'
);
for
(
const
branch
of
branches
)
{
for
(
const
branch
of
branches
)
{
addMeta
({
branch
:
branch
.
branchName
});
addMeta
({
branch
:
branch
.
branchName
});
const
res
=
await
processBranch
(
const
res
=
await
processBranch
(
...
@@ -39,7 +40,19 @@ export async function writeUpdates(
...
@@ -39,7 +40,19 @@ export async function writeUpdates(
// Stop procesing other branches because base branch has been changed
// Stop procesing other branches because base branch has been changed
return
res
;
return
res
;
}
}
prsRemaining
-=
res
===
'
pr-created
'
?
1
:
0
;
let
deductPrRemainingCount
=
0
;
if
(
res
===
'
pr-created
'
)
{
deductPrRemainingCount
=
1
;
}
// istanbul ignore if
if
(
res
===
'
automerged
'
&&
config
.
automergeType
===
'
pr-comment
'
&&
config
.
requiredStatusChecks
===
null
)
{
deductPrRemainingCount
=
1
;
}
prsRemaining
-=
deductPrRemainingCount
;
}
}
removeMeta
([
'
branch
'
]);
removeMeta
([
'
branch
'
]);
return
'
done
'
;
return
'
done
'
;
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment