Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merge main into v1 #704

Merged
merged 41 commits into from
Aug 16, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
41 commits
Select commit Hold shift + click to select a range
a0ab484
Bump eslint-plugin-import from 2.23.4 to 2.24.0
dependabot[bot] Aug 9, 2021
38bb211
Bump @ava/typescript from 1.1.1 to 2.0.0
dependabot[bot] Aug 9, 2021
183487b
Bump @typescript-eslint/parser from 4.29.0 to 4.29.1
dependabot[bot] Aug 9, 2021
068ade0
Update checked-in dependencies
invalid-email-address Aug 9, 2021
d6a5bf5
Update checked-in dependencies
invalid-email-address Aug 9, 2021
952b269
Update checked-in dependencies
invalid-email-address Aug 9, 2021
2175328
Updates the permissions block to be minimal
aeisenberg Aug 9, 2021
bb0eba1
Update changelog and version after v1.0.11
invalid-email-address Aug 9, 2021
5ba154a
1.0.12
invalid-email-address Aug 9, 2021
9ad3f82
Update checked-in dependencies
invalid-email-address Aug 9, 2021
89e4b4f
Merge pull request #697 from github/mergeback/v1.0.11-to-main-db7158f9
adityasharad Aug 9, 2021
61fb5d7
Merge branch 'main' into aeisenberg/update-permissions
aeisenberg Aug 9, 2021
07fa17d
Merge pull request #689 from github/aeisenberg/update-permissions
aeisenberg Aug 9, 2021
46ddfc6
Merge branch 'main' into dependabot/npm_and_yarn/ava/typescript-2.0.0
henrymercer Aug 11, 2021
75d42be
Add `compile` property to ava configuration
henrymercer Aug 11, 2021
743d8df
Always run the `latest` tools PR checks so we can make them required
henrymercer Aug 11, 2021
8c8a933
Merge pull request #693 from github/dependabot/npm_and_yarn/ava/types…
henrymercer Aug 11, 2021
060eb52
Merge branch 'main' into dependabot/npm_and_yarn/eslint-plugin-import…
henrymercer Aug 11, 2021
93c9da2
Reference exported names via `import *`.
henrymercer Aug 11, 2021
1263b9c
Merge branch 'main' into henrymercer/allow-latest-checks-to-be-required
henrymercer Aug 11, 2021
0d88424
Merge pull request #699 from github/henrymercer/allow-latest-checks-t…
henrymercer Aug 11, 2021
3ebf977
Merge branch 'main' into dependabot/npm_and_yarn/eslint-plugin-import…
henrymercer Aug 11, 2021
fe83f96
Merge pull request #692 from github/dependabot/npm_and_yarn/eslint-pl…
henrymercer Aug 11, 2021
75aad21
Bump eslint-plugin-github from 4.1.5 to 4.2.0
dependabot[bot] Aug 11, 2021
46043e8
Tweak linting rule changes brought in by `eslint-plugin-github` upgrade
henrymercer Aug 11, 2021
4a0d337
Update checked-in dependencies
invalid-email-address Aug 11, 2021
873a76a
Merge pull request #698 from github/dependabot/npm_and_yarn/eslint-pl…
edoardopirovano Aug 11, 2021
5fd8ca8
Merge branch 'main' into dependabot/npm_and_yarn/typescript-eslint/pa…
henrymercer Aug 11, 2021
1e0763c
Update checked-in dependencies
invalid-email-address Aug 11, 2021
f1c75fc
Merge pull request #694 from github/dependabot/npm_and_yarn/typescrip…
henrymercer Aug 11, 2021
b19f1f9
Reduce the number of PR checks that are run on `push`
henrymercer Aug 11, 2021
a068a28
Add brief instructions on creating a release
henrymercer Aug 11, 2021
4e477f1
Add more details on the workflows involved in the release process
henrymercer Aug 11, 2021
962925a
Merge pull request #700 from github/henrymercer/reduce-num-pr-check-j…
henrymercer Aug 11, 2021
7f1659f
Merge branch 'main' into henrymercer/brief-releasing-instructions
henrymercer Aug 11, 2021
c7203c9
Fix conditional in PR checks
henrymercer Aug 11, 2021
bc33041
Always run `codeql (latest)` job on PRs so we can make it required
henrymercer Aug 11, 2021
acd9964
Merge pull request #701 from github/henrymercer/brief-releasing-instr…
henrymercer Aug 11, 2021
0c4306b
Pass `--ram` flag to `database finalize`
edoardopirovano Aug 12, 2021
01d17ea
Merge pull request #702 from github/pass-ram-flag
edoardopirovano Aug 12, 2021
3254fa5
1.0.12
invalid-email-address Aug 16, 2021
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions .eslintrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,14 @@
],
"rules": {
"filenames/match-regex": ["error", "^[a-z0-9-]+(\\.test)?$"],
"i18n-text/no-en": "off",
"import/extensions": "error",
"import/no-amd": "error",
"import/no-commonjs": "error",
"import/no-dynamic-require": "error",
"import/no-extraneous-dependencies": ["error"],
// Disable the rule that checks that devDependencies aren't imported since we use a single
// linting configuration file for both source and test code.
"import/no-extraneous-dependencies": ["error", {"devDependencies": true}],
"import/no-namespace": "off",
"import/no-unresolved": "error",
"import/no-webpack-loader-syntax": "error",
Expand Down Expand Up @@ -48,7 +51,8 @@
"@typescript-eslint/prefer-regexp-exec": "off",
"@typescript-eslint/require-await": "off",
"@typescript-eslint/restrict-template-expressions": "off",
"func-style": "off"
"func-style": "off",
"sort-imports": "off"
}
}]
}
16 changes: 9 additions & 7 deletions .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,6 @@ jobs:
versions: ${{ steps.compare.outputs.versions }}

permissions:
actions: read
contents: read
security-events: write

steps:
Expand Down Expand Up @@ -48,13 +46,19 @@ jobs:
CODEQL_VERSION_LATEST="$("$CODEQL_LATEST" version --format terse)"
echo "Default CodeQL bundle version is $CODEQL_VERSION_DEFAULT"
echo "Latest CodeQL bundle version is $CODEQL_VERSION_LATEST"
if [[ "$CODEQL_VERSION_DEFAULT" == "$CODEQL_VERSION_LATEST" ]]; then
# Just use `tools: null` to avoid duplication in the analysis job.

# If we're running on a pull request, run with both bundles, even if `tools: latest` would
# be the same as `tools: null`. This allows us to make the job for each of the bundles a
# required status check.
#
# If we're running on push, then we can skip running with `tools: latest` when it would be
# the same as running with `tools: null`.
if [[ "$GITHUB_EVENT_NAME" != "pull_request" && "$CODEQL_VERSION_DEFAULT" == "$CODEQL_VERSION_LATEST" ]]; then
VERSIONS_JSON='[null]'
else
# Use both `tools: null` and `tools: latest` in the analysis job.
VERSIONS_JSON='[null, "latest"]'
fi

# Output a JSON-encoded list with the distinct versions to test against.
echo "Suggested matrix config for analysis job: $VERSIONS_JSON"
echo "::set-output name=versions::${VERSIONS_JSON}"
Expand All @@ -68,8 +72,6 @@ jobs:
runs-on: ${{ matrix.os }}

permissions:
actions: read
contents: read
security-events: write

steps:
Expand Down
12 changes: 9 additions & 3 deletions .github/workflows/pr-checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -350,13 +350,19 @@ jobs:
echo "Default CodeQL bundle version is $CODEQL_VERSION_DEFAULT"
echo "Latest CodeQL bundle version is $CODEQL_VERSION_LATEST"
echo "Nightly CodeQL bundle version is $CODEQL_VERSION_NIGHTLY"
if [[ "$CODEQL_VERSION_DEFAULT" == "$CODEQL_VERSION_LATEST" ]]; then
# Skip `tools: latest` since it would be the same as `tools: null`

# If we're running on a pull request, run each integration test with all three bundles, even
# if `tools: latest` would be the same as `tools: null`. This allows us to make the
# integration test job for each of the three bundles a required status check.
#
# If we're running on push, then we can skip running with `tools: latest` when it would be
# the same as running with `tools: null`.
if [[ "$GITHUB_EVENT_NAME" != "pull_request" && "$CODEQL_VERSION_DEFAULT" == "$CODEQL_VERSION_LATEST" ]]; then
VERSIONS_JSON="[null, \"$NIGHTLY_URL\"]"
else
# Run integration tests with all three bundles.
VERSIONS_JSON="[null, \"$NIGHTLY_URL\", \"latest\"]"
fi

# Output a JSON-encoded list with the distinct versions to test against.
echo "Suggested matrix config for integration tests: $VERSIONS_JSON"
echo "::set-output name=versions::${VERSIONS_JSON}"
Expand Down
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# CodeQL Action and CodeQL Runner Changelog

## 1.0.12 - 16 Aug 2021

- Update README to include a sample permissions block. [#689](https://github.com/github/codeql-action/pull/689)

## 1.0.11 - 09 Aug 2021

- Update default CodeQL bundle version to 2.5.9. [#687](https://github.com/github/codeql-action/pull/687)
Expand Down
14 changes: 14 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,20 @@ Here are a few things you can do that will increase the likelihood of your pull
- Keep your change as focused as possible. If there are multiple changes you would like to make that are not dependent upon each other, consider submitting them as separate pull requests.
- Write a [good commit message](http://tbaggery.com/2008/04/19/a-note-about-git-commit-messages.html).

## Releasing (write access required)

1. The first step of releasing a new version of the `codeql-action` is running the "Update release branch" workflow.
This workflow goes through the pull requests that have been merged to `main` since the last release, creates a changelog, then opens a pull request to merge the changes since the last release into the `v1` release branch.

A release is automatically started every Monday via a scheduled run of this workflow, however you can start a release manually by triggering a run via [workflow dispatch](https://github.com/github/codeql-action/actions/workflows/update-release-branch.yml).
1. The workflow run will open a pull request titled "Merge main into v1". Mark the pull request as [ready for review](https://docs.github.com/en/github/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/changing-the-stage-of-a-pull-request#marking-a-pull-request-as-ready-for-review) to trigger the PR checks.
1. Review the checklist items in the pull request description.
Once you've checked off all but the last of these, approve the PR and automerge it.
1. When the "Merge main into v1" pull request is merged into the `v1` branch, the "Tag release and merge back" workflow will create a mergeback PR.
This mergeback incorporates the changelog updates into `main`, tags the release using the merge commit of the "Merge main into v1" pull request, and bumps the patch version of the CodeQL Action.

Approve the mergeback PR and automerge it. Once the mergeback has been merged into main, the release is complete.

## Resources

- [How to Contribute to Open Source](https://opensource.guide/how-to-contribute/)
Expand Down
8 changes: 8 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,14 @@ jobs:
# CodeQL runs on ubuntu-latest, windows-latest, and macos-latest
runs-on: ubuntu-latest

permissions:
# required for all workflows
security-events: write

# only required for workflows in private repositories
actions: read
contents: read

steps:
- name: Checkout repository
uses: actions/checkout@v2
Expand Down
8 changes: 4 additions & 4 deletions lib/actions-util.test.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion lib/actions-util.test.js.map

Large diffs are not rendered by default.

5 changes: 3 additions & 2 deletions lib/analyze-action.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion lib/analyze-action.js.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading