diff options
-rwxr-xr-x | gen.sh | 12 |
1 files changed, 11 insertions, 1 deletions
@@ -2,6 +2,16 @@ | |||
2 | 2 | ||
3 | FILELIST=`find . -type f -iname '*.png' -exec sh -c 'x=${0#./}; printf "%s:%s|" ${x%.svg.png} $x' {} \;` | 3 | FILELIST=`find . -type f -iname '*.png' -exec sh -c 'x=${0#./}; printf "%s:%s|" ${x%.svg.png} $x' {} \;` |
4 | 4 | ||
5 | jq -Rn 'input | split("|") | map(split(":") | { key: .[0], value: .[1] }) | from_entries' <<<"${FILELIST%|}">blobfox.json | 5 | jq -Rn 'input | split("|") | map(split(":") | { key: .[0], value: .[1] }) | from_entries' <<< "${FILELIST%|}" > blobfox.json |
6 | 6 | ||
7 | zip blobfox.zip *.png | 7 | zip blobfox.zip *.png |
8 | |||
9 | CHECKSUM=`sha256sum -z blobfox.zip | awk '{ print $1 }'` | ||
10 | |||
11 | printf '{ | ||
12 | "src": "https://git.pleroma.social/pleroma/emoji-index/raw/master/packs/blobfox.zip", | ||
13 | "src_sha256": "%s", | ||
14 | "license": "Apache 2.0", | ||
15 | "files": "blobfox.json", | ||
16 | "description": "Like Blobcat, except with foxes" | ||
17 | }' $CHECKSUM > index.json | ||