Skip to content

Instantly share code, notes, and snippets.

@davidwessman
Last active July 29, 2022 15:15
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save davidwessman/d7e2d4b15619802a595cc96a2f583927 to your computer and use it in GitHub Desktop.
Save davidwessman/d7e2d4b15619802a595cc96a2f583927 to your computer and use it in GitHub Desktop.
Action to upgrade Gemfile.next.lock
name: Update next
on:
pull_request:
paths:
- "Gemfile.lock"
jobs:
update:
runs-on: ubuntu-20.04
env:
BUNDLE_GEMFILE: Gemfile.next
steps:
- name: Generate token
id: generate_token
uses: tibdex/github-app-token@v1
with:
app_id: ${{ secrets.APP_ID }}
private_key: ${{ secrets.PRIVATE_KEY }}
- uses: actions/checkout@v2
with:
token: ${{ steps.generate_token.outputs.token }}
- name: Set up Ruby
uses: ruby/setup-ruby@v1
- name: Gems Cache
id: gem-cache
uses: actions/cache@v2
with:
path: vendor/bundle
key: ${{ runner.os }}-gem-${{ hashFiles('Gemfile.next.lock') }}
restore-keys: |
${{ runner.os }}-gem-
- name: Update Gemfile.next
run: |
bundle update --minor --conservative
- uses: EndBug/add-and-commit@v6
with:
add: Gemfile.next.lock
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment