diff options
| author | Ogulcan Celik <ogulcancelik@gmail.com> | 2026-05-20 18:55:41 +0300 |
|---|---|---|
| committer | Ogulcan Celik <ogulcancelik@gmail.com> | 2026-05-20 18:55:41 +0300 |
| commit | 836fd7e585af15cc1ccb0d4f04586ffec28d2a3c (patch) | |
| tree | a3bf07e7af7ffd884a38fce3d65f8c2243bc0615 /.github | |
| parent | be66f33d2acde30d25794bcead991e5e7b7eaff8 (diff) | |
feat: add keybinding v2
refs #154
refs #201
refs #202
refs #219
Diffstat (limited to '.github')
| -rw-r--r-- | .github/workflows/release.yml | 30 |
1 files changed, 27 insertions, 3 deletions
diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index c5c84f66..9ec6a4cf 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -109,8 +109,21 @@ jobs: name: ${{ matrix.name }} path: ${{ matrix.name }} + validate-release-inputs: + runs-on: ubuntu-latest + permissions: + contents: read + + steps: + - uses: actions/checkout@v6 + with: + persist-credentials: false + + - name: Validate product announcement + run: python3 scripts/changelog.py validate-product-announcement + release: - needs: build + needs: [build, validate-release-inputs] runs-on: ubuntu-latest permissions: contents: write @@ -280,18 +293,29 @@ jobs: GH_TOKEN: ${{ github.token }} run: | VERSION="${GITHUB_REF_NAME#v}" + ANNOUNCEMENT_PATH="$RUNNER_TEMP/product-announcement.json" + ANNOUNCEMENT_ORIGINAL_PATH="$RUNNER_TEMP/product-announcement-original.json" + git show "${GITHUB_REF_NAME}:docs/next/product-announcement.json" > "$ANNOUNCEMENT_PATH" + cp "$ANNOUNCEMENT_PATH" "$ANNOUNCEMENT_ORIGINAL_PATH" + python3 scripts/changelog.py validate-product-announcement --path "$ANNOUNCEMENT_PATH" + CURRENT_VERSION=$(python3 -c 'import json; print(json.load(open("website/latest.json")).get("version", ""))') if [ "$CURRENT_VERSION" = "$VERSION" ]; then echo "website/latest.json is already at v$VERSION" exit 0 fi - python3 scripts/changelog.py sync-latest-json --version "$VERSION" --output website/latest.json + python3 scripts/changelog.py sync-latest-json --version "$VERSION" --output website/latest.json --announcement "$ANNOUNCEMENT_PATH" + if cmp -s "$ANNOUNCEMENT_ORIGINAL_PATH" docs/next/product-announcement.json; then + printf 'null\n' > docs/next/product-announcement.json + else + echo "::warning::docs/next/product-announcement.json changed after $GITHUB_REF_NAME; leaving it unchanged." + fi - name: Commit website latest manifest run: | VERSION="${GITHUB_REF_NAME#v}" git config user.name "github-actions[bot]" git config user.email "41898282+github-actions[bot]@users.noreply.github.com" - git add website/latest.json + git add website/latest.json docs/next/product-announcement.json git diff --cached --quiet || git commit -m "docs: update website manifest for v$VERSION" git push origin master |
