From 80a727087dda3a853b735ba98bd265d01465cc08 Mon Sep 17 00:00:00 2001 From: multipleof4 Date: Wed, 3 Sep 2025 13:51:17 -0700 Subject: [PATCH] Create catalog.yml --- .github/workflows/catalog.yml | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 .github/workflows/catalog.yml diff --git a/.github/workflows/catalog.yml b/.github/workflows/catalog.yml new file mode 100644 index 0000000..a9ce8da --- /dev/null +++ b/.github/workflows/catalog.yml @@ -0,0 +1,18 @@ +on: push +permissions: + contents: write +jobs: + c: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - run: > + printf '['>catalog.json;c=; + for f in *;do [ -f "$f" ]||continue;[ "${f:0:1}" = . ]&&continue; + printf '%s{"name":"%s","raw":"https://raw.githubusercontent.com/%s/%s/%s","content":"' "$c" "$f" "$GITHUB_REPOSITORY" "$GITHUB_REF_NAME" "$f">>catalog.json; + base64 -w0 "$f">>catalog.json;printf '"}'>>catalog.json;c=,;done;printf ']' + >>catalog.json; + git diff --quiet -- catalog.json||( + git add catalog.json; + git -c user.name=bot -c user.email=bot@users.noreply.github.com commit -m update; + git push )