Skip to content

Use a dedicated workflow for each sync type #7

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jun 15, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
46 changes: 46 additions & 0 deletions .github/workflows/check-dependabot-sync.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
# This repository contains intentionally duplicated copies of template workflows under
# workflow-templates/dependabot/workflow-template-copies used for Dependabot checks.
#
# This workflow checks that the copies are in sync.
# If the workflow fails, run `task fix` and commit.

name: Check Workflow Duplicates Sync

on:
push:
paths:
- ".github/workflows/check-dependabot-sync.ya?ml"
- "Taskfile.yml"
- "workflow-templates/*.ya?ml"
- "workflow-templates/dependabot/workflow-template-copies/.github/workflows/*"
pull_request:
paths:
- ".github/workflows/check-dependabot-sync.ya?ml"
- "Taskfile.yml"
- "workflow-templates/*.ya?ml"
- "workflow-templates/dependabot/workflow-template-copies/.github/workflows/*"

jobs:
check-sync:
runs-on: ubuntu-latest

steps:
- name: Checkout repository
uses: actions/checkout@v2

- name: Install Task
uses: arduino/setup-task@v1
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
version: 3.x

- name: Sync workflows
run: task --silent dependabot:sync

- name: Check workflow duplicates sync
run: |
git add .
if ! git diff --color --exit-code HEAD; then
echo "::error::Workflow duplicates are out of sync. Please run \"task fix\""
exit 1
fi
41 changes: 0 additions & 41 deletions .github/workflows/check-sync.yml

This file was deleted.

2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

[![Check Configuration Files status](https://github.com/arduino/tooling-project-assets/actions/workflows/check-configuration-files.yml/badge.svg)](https://github.com/arduino/tooling-project-assets/actions/workflows/check-configuration-files.yml)
[![Check License status](https://github.com/arduino/tooling-project-assets/actions/workflows/check-license.yml/badge.svg)](https://github.com/arduino/tooling-project-assets/actions/workflows/check-license.yml)
[![Check File Duplicates Sync status](https://github.com/arduino/tooling-project-assets/actions/workflows/check-sync.yml/badge.svg)](https://github.com/arduino/tooling-project-assets/actions/workflows/check-sync.yml)
[![Check Workflow Duplicates Sync status](https://github.com/arduino/tooling-project-assets/actions/workflows/check-dependabot-sync.yml/badge.svg)](https://github.com/arduino/tooling-project-assets/actions/workflows/check-dependabot-sync.yml)

The [Arduino](https://www.arduino.cc/) Tooling Team's collection of reusable project infrastructure assets.

Expand Down