Skip to content

Commit

Permalink
try file sync action
Browse files Browse the repository at this point in the history
  • Loading branch information
rwaffen committed May 31, 2024
1 parent c42783c commit d5272c6
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 58 deletions.
24 changes: 0 additions & 24 deletions .github/release.yml

This file was deleted.

23 changes: 23 additions & 0 deletions .github/workflows/config_sync.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: File Sync ♻️

on:
push:
branches:
- main
schedule:
- cron: "*/5 * * * *"

jobs:
file_sync:
runs-on: ubuntu-latest
steps:
- name: Fetching Local Repository
uses: actions/checkout@main
- name: File Sync
uses: kbrashears5/github-action-file-sync@v2.0.0
with:
REPOSITORIES: |
"${{ github.repository_owner }}/.github@main"
FILES: |
.github/release.yml=.github/release.yml
TOKEN: ${{ secrets.ACTIONS }}
36 changes: 2 additions & 34 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,37 +11,5 @@ jobs:
name: Release
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Prüfe, ob release.yml existiert
id: check_file
run: |
if [ ! -f .github/release.yml ]; then
echo "RELEASE_YML_MISSING=true" >> $GITHUB_OUTPUT
fi
- name: Checkout Upstream-Repository (falls release.yml fehlt)
uses: actions/checkout@v4
if: steps.check_file.outputs.RELEASE_YML_MISSING == 'true'
with:
repository: "${{ github.repository_owner }}/.github"
path: upstream
sparse-checkout: .github/release.yml
sparse-checkout-cone-mode: false

- name: Kopiere release.yml (falls vorhanden)
if: steps.check_file.outputs.RELEASE_YML_MISSING == 'true'
run: |
cp upstream/.github/release.yml .github/release.yml
- name: list files
run: find .

- name: Create Release Page
shell: bash
env:
GH_TOKEN: ${{ github.token }}
run: gh release create ${{ github.ref_name }} --generate-notes
- name: Create GitHub release
uses: voxpupuli/gha-create-a-github-release@main

0 comments on commit d5272c6

Please sign in to comment.