Skip to content

lab: add restic local snapshots #394

lab: add restic local snapshots

lab: add restic local snapshots #394

Workflow file for this run

# SPDX-FileCopyrightText: Andrew Hayzen <[email protected]>
#
# SPDX-License-Identifier: MPL-2.0
name: auto merge
on:
pull_request_target:
workflow_dispatch:
permissions:
pull-requests: write
contents: write
jobs:
auto-merge:
runs-on: ubuntu-22.04
# Auto merge if this is
# - dependabot
# - ahayzen-nix-config-bot performing a chore
if: "${{ github.event.pull_request.user.login == 'dependabot[bot]' || (github.event.pull_request.user.login == 'ahayzen-nix-config-bot[bot]' && startsWith(github.event.pull_request.title, 'chore')) }}"
steps:
- name: approve the pr
run: gh pr review $PR_URL --approve
env:
PR_URL: ${{ github.event.pull_request.html_url }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: auto-merge the pr
run: gh pr merge --auto --delete-branch --rebase "$PR_URL"
env:
PR_URL: ${{ github.event.pull_request.html_url }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}