Skip to content

Commit

Permalink
ci: release-PR using standard-version
Browse files Browse the repository at this point in the history
  • Loading branch information
jnoortheen committed Jan 24, 2025
1 parent ce091fb commit 10d1e17
Show file tree
Hide file tree
Showing 3 changed files with 49 additions and 23 deletions.
25 changes: 2 additions & 23 deletions .github/workflows/ci.yaml → .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -1,35 +1,14 @@
name: VSCode CI
name: publish the extension to marketplaces

on:
push:
branches: [master, main]
tags:
- "v*"
pull_request:
branches: [master, main]

jobs:
build:
runs-on: ${{ matrix.os }}

strategy:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]

steps:
- uses: actions/checkout@v4
- uses: oven-sh/setup-bun@v2
- run: bun install
- run: bun run lint
- run: bun run build
- run: bun run pretest

# publish the extension to marketplaces
publish:
# run after lint passes
needs: build
runs-on: ubuntu-latest
if: startsWith(github.ref, 'refs/tags/v')
if: github.ref == 'refs/heads/main'
steps:
- uses: actions/checkout@v4
- uses: oven-sh/setup-bun@v2
Expand Down
22 changes: 22 additions & 0 deletions .github/workflows/release-pr.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: VSCode CI

on:
push:
branches: [main]

jobs:
create_release_pr:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: oven-sh/setup-bun@v2
- run: bun install
- run: bunx standard-version
- name: Create Pull Request
uses: peter-evans/create-pull-request@v4
with:
commit-message: "chore(release): update version and changelog"
branch: release-branch
title: "Release PR"
body: "This PR contains the changes from running bunx standard-version."
labels: release
25 changes: 25 additions & 0 deletions .github/workflows/test.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: VSCode CI

on:
push:
branches: [master, main]
tags:
- "v*"
pull_request:
branches: [master, main]

jobs:
build:
runs-on: ${{ matrix.os }}

strategy:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]

steps:
- uses: actions/checkout@v4
- uses: oven-sh/setup-bun@v2
- run: bun install
- run: bun run lint
- run: bun run build
- run: bun run pretest

0 comments on commit 10d1e17

Please sign in to comment.