Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
4 changes: 3 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,4 +33,6 @@ jobs:
with:
token: ${{ secrets.CODECOV_TOKE }}
fail_ci_if_error: true
verbose: true
verbose: true
env:
CODECOV_GPG_VERIFY: false
57 changes: 57 additions & 0 deletions .github/workflows/release-create-pr.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
name: Create Release Pull Request

on:
push:
branches:
- main

jobs:
create_release_pr:
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 18

- name: Install dependencies
run: npm ci

- name: Run standard-version (bump version and changelog)
run: npx standard-version

- name: Get new version tag
id: get_version
run: echo "tag=$(node -p \"require('./package.json').version\")" >> $GITHUB_OUTPUT

- name: Configure git
run: |
git config user.name "github-actions[bot]"
git config user.email "github-actions[bot]@users.noreply.github.com"

- name: Create release branch and push
env:
GITHUB_PAT: ${{ secrets.TOKEN_GITHUB }}
RELEASE_BRANCH: release/v${{ steps.get_version.outputs.tag }}
run: |
git checkout -b $RELEASE_BRANCH
git push origin $RELEASE_BRANCH

- name: Create Pull Request
env:
GITHUB_TOKEN: ${{ secrets.TOKEN_GITHUB }}
run: |
sudo apt-get update
sudo apt-get install -y gh
echo "${GITHUB_TOKEN}" | gh auth login --with-token
gh pr create --title "Release v${{ steps.get_version.outputs.tag }}" \
--body "Release automática da versão v${{ steps.get_version.outputs.tag }}" \
--base main --head $RELEASE_BRANCH \
--reviewer gustavomarques00 \
--assignee gustavomarques00
6 changes: 3 additions & 3 deletions .github/workflows/release-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,18 +3,18 @@ name: Release and Publish
on:
push:
branches:
- main # Executa apenas quando push for para a main
- main

jobs:
release:
name: Version bump, changelog, release & publish
name: Publish package to npm
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0 # Necessário para tags e histórico completo
fetch-depth: 0

- name: Setup Node.js
uses: actions/setup-node@v4
Expand Down