Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 4b4a5ee

Browse files
authored
Merge pull request #534 from github/aeisenberg/mergeback-fix
Fix the mergeback workflow
2 parents ca94508 + f0e82b7 commit 4b4a5ee

7 files changed

Lines changed: 18 additions & 14 deletions

File tree

.github/update-release-branch.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,7 @@
88
import datetime
99
import os
1010

11-
EMPTY_CHANGELOG = """
12-
# CodeQL Action and CodeQL Runner Changelog
11+
EMPTY_CHANGELOG = """# CodeQL Action and CodeQL Runner Changelog
1312
1413
## [UNRELEASED]
1514

.github/workflows/post-release-mergeback.yml

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -74,24 +74,27 @@ jobs:
7474
set +e # don't fail on an errored command
7575
git ls-remote --tags origin | grep "$VERSION"
7676
EXISTS="$?"
77-
if [ "$EXISTS" -ne 0 ]; then
78-
echo "::set-output name=exists::true"
79-
echo "Tag $TAG exists. Not going to re-release."
77+
if [ "$EXISTS" -eq 0 ]; then
78+
echo "Tag $TAG exists. Not going to re-release."
79+
echo "::set-output name=exists::true"
80+
else
81+
echo "Tag $TAG does not exist yet."
8082
fi
8183
8284
# we didn't tag the release during the update-release-branch workflow because the
8385
# commit that actually makes it to the release branch is a merge commit,
8486
# and not yet known during the first workflow. We tag now because we know the correct commit.
8587
- name: Tag release
86-
if: steps.check.outputs.exists == 'true'
88+
if: steps.check.outputs.exists != 'true'
8789
env:
8890
VERSION: ${{ steps.getVersion.outputs.version }}
8991
run: |
9092
git tag -a "$VERSION" -m "$VERSION"
93+
git fetch --unshallow # unshallow the repo in order to allow pushes
9194
git push origin --follow-tags "$VERSION"
9295
9396
- name: Create mergeback branch
94-
if: steps.check.outputs.exists == 'true'
97+
if: steps.check.outputs.exists != 'true'
9598
env:
9699
VERSION: "${{ steps.getVersion.outputs.version }}"
97100
NEW_BRANCH: "${{ steps.getVersion.outputs.newBranch }}"

CHANGELOG.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22

33
## [UNRELEASED]
44

5+
## 1.0.0 - 31 May 2021
6+
57
- Add this changelog file. [#507](https://github.com/github/codeql-action/pull/507)
68
- Improve grouping of analysis logs. Add a new log group containing a summary of metrics and diagnostics, if they were produced by CodeQL builtin queries. [#515](https://github.com/github/codeql-action/pull/515)
7-
- Add metrics and diagnostics summaries from custom query suites to the analysis summary log group. [#532](https://github.com/github/codeql-action/pull/532)
9+
- Add metrics and diagnostics summaries from custom query suites to the analysis summary log group. [#532](https://github.com/github/codeql-action/pull/532)

package-lock.json

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "codeql",
3-
"version": "1.0.0",
3+
"version": "1.0.1",
44
"private": true,
55
"description": "CodeQL action",
66
"scripts": {
@@ -10,7 +10,7 @@
1010
"lint": "eslint --report-unused-disable-directives --max-warnings=0 . --ext .js,.ts",
1111
"lint-fix": "eslint --report-unused-disable-directives --max-warnings=0 . --ext .js,.ts --fix",
1212
"removeNPMAbsolutePaths": "removeNPMAbsolutePaths . --force",
13-
"version": "cd runner && npm version patch && git add ."
13+
"version": "cd runner && npm version patch && cd .. && npm run removeNPMAbsolutePaths && git add runner"
1414
},
1515
"ava": {
1616
"typescript": {

runner/package-lock.json

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

runner/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "codeql-runner",
3-
"version": "1.0.0",
3+
"version": "1.0.1",
44
"private": true,
55
"description": "CodeQL runner",
66
"scripts": {

0 commit comments

Comments
 (0)