Skip to content

Commit 0ae330f

Browse files
committed
Automatically update descriptions on Docker Hub
1 parent 733f258 commit 0ae330f

File tree

1 file changed

+57
-0
lines changed

1 file changed

+57
-0
lines changed
Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
name: Update Docker Hub Description
2+
on:
3+
push:
4+
branches:
5+
- main
6+
# REMOVE BEFORE FLIGHT: for testing
7+
- dockerhub-descriptions
8+
# paths:
9+
# - versions.md
10+
# - README.md
11+
# - docs/**/*
12+
13+
workflow_dispatch:
14+
15+
jobs:
16+
updateDescriptions:
17+
name: Update description on Docker Hub
18+
runs-on: ubuntu-latest
19+
strategy:
20+
matrix:
21+
image:
22+
- minimal
23+
- core
24+
- latex
25+
- extra
26+
- typst
27+
28+
steps:
29+
- name: Checkout
30+
uses: actions/checkout@v4
31+
32+
- name: Setup pandoc
33+
uses: pandoc/actions/setup@v1
34+
35+
- name: Short description
36+
id: config
37+
run: |
38+
set -e
39+
ls -l
40+
printf 'short_description=%s\n' \
41+
"$(pandoc lua docs/scripts/short-description.lua \
42+
${{ matrix.image }})" \
43+
>> $GITHUB_OUTPUT
44+
45+
46+
- name: Generate README files
47+
run: |
48+
make docs-${{ matrix.image }} > /tmp/README.${{ matrix.image }}.md
49+
50+
- name: minimal
51+
uses: peter-evans/dockerhub-description@e98e4d1628a5f3be2be7c231e50981aee98723ae
52+
with:
53+
username: ${{ secrets.DOCKER_HUB_USERNAME }}
54+
password: ${{ secrets.DOCKER_HUB_TOKEN }}
55+
repository: pandoc/${{ matrix.image }}
56+
readme-filepath: /tmp/README.${{ matrix.image }}.md
57+
short-description: ${{ steps.config.outputs.short_description }}

0 commit comments

Comments
 (0)