Skip to content

👷 test

👷 test #32

# This is a basic workflow to help you get started with Actions
name: sync upstream trigger
# Controls when the workflow will run
on:
# Triggers the workflow on push or pull request events but only for the "main" branch
push:
branches: [ "main" ]
# paths:
# - "**.lua"
pull_request:
branches: [ "main" ]
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
env:
TARGET_REPO: dotfiles.nix
TARGET_WORKFLOW_FILE: sync-upstream.yml
INPUT_REPO: ${{ github.event.repository.name }}
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
# This workflow contains a single job called "build"
build:
# The type of runner that the job will run on
runs-on: ubuntu-latest
# Steps represent a sequence of tasks that will be executed as part of the job
steps:
- name: Generate GitHub auth token
# https://github.com/tibdex/github-app-token
id: generate_token
uses: tibdex/github-app-token@v2.1.0
with:
app_id: ${{ secrets.GH_APP_ID }}
private_key: ${{ secrets.GH_APP_PRIVATE_KEY }}
- run: echo "REPO_NAME=${{ env.INPUT_REPO }}" >> $GITHUB_ENV
- uses: convictional/trigger-workflow-and-wait@v1.6.5
name: sync dotfiles
with:
owner: ${{ github.repository_owner }}
repo: ${{ env.TARGET_REPO }}
github_token: ${{ steps.generate_token.outputs.token }}
# github_user: "my-action-bot"
workflow_file_name: ${{ env.TARGET_WORKFLOW_FILE }}
ref: ${{ env.TARGET_BRANCH }}
wait_interval: 10
client_payload: '{"input": "${{ env.REPO_NAME }}"}'
propagate_failure: false
trigger_workflow: true
wait_workflow: true