Getting Started with Bricks Action
Set up the Bricks GitHub Action to run CLI commands in GitHub workflows for automated version bumping, publishing, and deployment
Last updated
Was this helpful?
Was this helpful?
name: 'Update Artifacts and Blueprints'
on:
pull_request:
types: [opened, synchronize, reopened]
pull_request_review:
types: [submitted]
permissions:
id-token: write
contents: write
pull-requests: write
jobs:
updateci:
runs-on: ubuntu-latest
if: |
(github.event_name == 'pull_request') ||
(github.event_name == 'pull_request_review' && github.event.review.state == 'approved')
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
persist-credentials: false
ref: ${{ github.event.pull_request.head.ref }} # This is the PR branch
- name: Run updateci Command
uses: bluebricks-co/bricks-action@main
with:
command: 'updateci'
artifacts-folder: 'bluebricks/packages'
blueprints-folder: 'bluebricks/blueprints'
artifact-bump: 'patch'
blueprint-bump: 'patch'
base: 'origin/master'
api-key: ${{ secrets.BRICKS_API_KEY }}
config-file: ${{ github.workspace }}/config-dev.yaml
flags: ${{ github.event_name == 'pull_request' && '--dry' || '' }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}