Skip to content

Commit

Permalink
build only on main and PRs
Browse files Browse the repository at this point in the history
  • Loading branch information
cultivator[bot] committed Jul 4, 2023
1 parent b5a7b3e commit 8440254
Showing 1 changed file with 9 additions and 8 deletions.
17 changes: 9 additions & 8 deletions .github/workflows/build.yml
@@ -1,5 +1,6 @@
---
name: Build
on:
'on':
pull_request:
push:
jobs:
Expand All @@ -12,7 +13,7 @@ jobs:
- name: Checkout
uses: actions/checkout@v3
with:
ref: ${{ github.ref_name }}
ref: "${{ github.ref_name }}"
fetch-depth: 0
submodules: recursive
- uses: ruby/setup-ruby@v1
Expand All @@ -22,16 +23,16 @@ jobs:
- name: Build
run: bundle exec rake
- name: Release
if: ${{ github.ref == 'refs/heads/main' }}
if: "${{ github.ref == 'refs/heads/main' }}"
run: |
git config --global user.email '41898282+github-actions[bot]@users.noreply.github.com'
git config --global user.name 'GitHub Actions'
bundle exec rake release
env:
BLACKSMITH_FORGE_API_KEY: ${{ secrets.BLACKSMITH_FORGE_API_KEY }}
BLACKSMITH_FORGE_API_KEY: "${{ secrets.BLACKSMITH_FORGE_API_KEY }}"
- name: Post to hook-exporter
run: ./.github/exporter.sh
run: "./.github/exporter.sh"
env:
EXPORTER_TOKEN: ${{ secrets.EXPORTER_TOKEN }}
JOB_STATUS: ${{ job.status }}
if: ${{ always() }}
EXPORTER_TOKEN: "${{ secrets.EXPORTER_TOKEN }}"
JOB_STATUS: "${{ job.status }}"
if: "${{ always() }}"

0 comments on commit 8440254

Please sign in to comment.