Skip to content

Commit

Permalink
Add update bsb Github Action (#65)
Browse files Browse the repository at this point in the history
  • Loading branch information
astley92 authored Oct 20, 2024
1 parent 716e1e2 commit 83c6bd8
Show file tree
Hide file tree
Showing 2 changed files with 40 additions and 0 deletions.
38 changes: 38 additions & 0 deletions .github/workflows/update_bsb_db.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: Update BSB DB

on:
workflow_dispatch:
schedule:
- cron: "0 15 1,8,15,22,29 * *" # “At 15:00 on day-of-month 1, 8, 15, 22, and 29.”

jobs:
update-bsb:
runs-on: ubuntu-latest
env:
AUSPAYNET_SUB_KEY: ${{secrets.AUSPAYNET_SUB_KEY}}
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Setup Ruby
uses: ruby/setup-ruby@v1
with:
bundler-cache: true

- name: Fetch latest contents
run: bundle exec rake bsb:sync_bsb_db

- name: Remove latest_update file
run: rm -f config/latest_update.json

- name: Create Pull Request
uses: peter-evans/create-pull-request@v7
with:
branch: update-bsb-db
title: Update BSB Database
body: |
This Pull Request was created via a Github Action.
The related workflow file is `.github/workflows/update_bsb_db.yml` and the changes are generated using the rake task `bsb:sync_bsb_db`
If you're unsure how to proceed with this PR, please see the [README](https://github.com/coinjar/bsb/blob/master/README.md#update-bsb-db)
2 changes: 2 additions & 0 deletions lib/bsb/aus_pay_net/client.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# frozen_string_literal: true

require("faraday")

module BSB
module AusPayNet
module Client
Expand Down

0 comments on commit 83c6bd8

Please sign in to comment.