We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 73a1da1 commit 2ef931aCopy full SHA for 2ef931a
.github/workflows/sync-gist.yml
@@ -0,0 +1,25 @@
1
+name: Sync Markdown to Gist
2
+
3
+on:
4
+ push:
5
+ paths:
6
+ - 'notes/questions.md'
7
+jobs:
8
+ update-gist:
9
+ runs-on: ubuntu-latest
10
11
+ steps:
12
+ - name: Checkout repo
13
+ uses: actions/checkout@v3
14
15
+ - name: Update Gist content
16
+ env:
17
+ GIST_TOKEN: ${{ secrets.GIST_TOKEN }}
18
+ run: |
19
+ FILE_CONTENT=$(cat yourfile.md | jq -Rs .)
20
+ GIST_ID=076468498c7f080b3a6d0c1f8c618b19
21
22
+ curl -X PATCH \
23
+ -H "Authorization: token $GIST_TOKEN" \
24
+ -d "{\"files\": {\"notes/questions.md\": {\"content\": $FILE_CONTENT}}}" \
25
+ https://api.github.com/gists/$GIST_ID
0 commit comments