forked from open-telemetry/opentelemetry-helm-charts
-
Notifications
You must be signed in to change notification settings - Fork 0
37 lines (30 loc) · 898 Bytes
/
Copy pathsync-readme.yaml
File metadata and controls
37 lines (30 loc) · 898 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
name: Sync README to gh-pages
permissions: {}
on:
push:
branches:
- main
paths:
- 'README.md'
jobs:
sync:
permissions:
contents: write
runs-on: ubuntu-latest
steps:
- name: Checkout main
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
- name: Copy README to temp
run: cp -f README.md ${{ runner.temp }}/README.md
- name: Checkout gh-pages
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
ref: gh-pages
- name: Sync README and push
run: |
cp -f ${{ runner.temp }}/README.md .
git config user.name "$GITHUB_ACTOR"
git config user.email "$GITHUB_ACTOR@users.noreply.github.com"
git add README.md
git commit --signoff -m "Sync README from main" || exit 0
git push