Repository navigation
chore: Automate release process - #8177
camdecoster wants to merge 8 commits into
Conversation
| fi | ||
|
|
||
| MISSING_LINK="" | ||
| LEADING_SPACE="" |
There was a problem hiding this comment.
nit: the name confused me since there's no space in LEADING_SPACE :) Should we call this something like BAD_INDENT_FILES?
| contents: write | ||
| id-token: write |
There was a problem hiding this comment.
Rather than blanket write permissions for every command in this job, what about replacing the git push with a targeted
git push "https://x-access-token:${GH_TOKEN}@github.com/${{ github.repository }}.git" "v$VERSION"
My thinking: the permissions granted here will also apply to the npm ci step (which runs arbitrary scripts from various dependencies - we trust there's no malicious ones but we can't know). And an automated process will invite less review and less awareness of any funky behaviour during a release, so we should keep the write permissions narrow.
| - name: Audit the dependencies | ||
| id: audit | ||
| env: | ||
| SKIP_AUDIT: ${{ inputs.skip-audit }} | ||
| run: | | ||
| set -uo pipefail | ||
| if npm audit > "$RUNNER_TEMP/audit.txt"; then | ||
| cat "$RUNNER_TEMP/audit.txt" | ||
| exit 0 | ||
| fi | ||
| cat "$RUNNER_TEMP/audit.txt" | ||
| if [ "$SKIP_AUDIT" != "true" ]; then | ||
| echo "::error::npm audit reported vulnerabilities. Fix them on main, or run this workflow again with skip-audit." | ||
| exit 1 | ||
| fi | ||
| echo "::warning::npm audit reported vulnerabilities. The release continues because skip-audit is set." | ||
| echo "skipped=true" >> "$GITHUB_OUTPUT" |
There was a problem hiding this comment.
What do you think about using npm audit --omit=dev?
That way we'd only check what users actually install, and not block ourselves for dev dependency issues.
| "name": "plotly.js", | ||
| "version": "4.3.0", | ||
| "description": "The open source javascript graphing library that powers plotly", | ||
| "description": "The open source JavaScript graphing library that powers plotly.py and Plotly Dash", |
There was a problem hiding this comment.
nit: to me, the sentence plays down that this is a standalone library in its own right. Also applies to bower.json, composer.json.
| "description": "The open source JavaScript graphing library that powers plotly.py and Plotly Dash", | |
| "description": "The open source JavaScript graphing library that also powers plotly.py and Plotly Dash", |
Description
Add workflows to automate the release process and update docs accordingly. See the image below for the flow.
Closes #8136.
Changes
Testing
We'll only be able to fully test this after merge as the workflows run on workflow dispatch.
Notes
Flow diagram