Skip to content

Test Sync Files

Test Sync Files #122

# Candace Savonen Aug 2021
name: Test Sync Files
on:
workflow_dispatch:
inputs:
repo:
description: 'What repo to test on e.g. jhudsl/OTTR_Template_Test'
required: true
default: 'jhudsl/OTTR_Template_Test'
jobs:
test-sync:
runs-on: ubuntu-latest
container:
image: jhudsl/base_ottr:main
steps:
- name: Checkout Repository
uses: actions/checkout@master
- name: Login as github actions bot
run: |
git config --global --add safe.directory $GITHUB_WORKSPACE
git config --global user.name 'github-actions[bot]'
git config --global user.email 'github-actions[bot]@users.noreply.github.com'
- name: Set up test-sync.yml
run: |
cp .github/sync.yml .github/test-sync.yml
# Switch out repo argument
Rscript --vanilla .github/switch_sync_repo.R --repo ${{ github.event.inputs.repo }}
- name: Run Mechanics File Sync
uses: BetaHuhn/repo-file-sync-action@v1.17.21
with:
GH_PAT: ${{ secrets.GH_PAT }}
COMMIT_BODY: "test-run"
CONFIG_PATH: .github/test-sync.yml