Created script to generate a Pleroma emoji pack

master
Feuerfuchs 5 years ago
parent 2c871bf40e
commit 97a5a1ea71
No known key found for this signature in database
GPG Key ID: 9953BC7CB26FB049

2
.gitignore vendored

@ -1 +1,3 @@
*.png
*.json
*.zip

@ -0,0 +1,15 @@
#!/bin/sh
IDS=`find . -type f -iname '*.png' -exec sh -c 'x=${0#./}; printf "%s|" ${x%.svg.png}' {} \;`
FILES=`find . -type f -iname '*.png' -exec sh -c 'printf "%s|" ${0#./}' {} \;`
FILELIST="${IDS%|}
${FILES%|}"
jq -Rn '
( input | split("|") ) as $keys |
( inputs | split("|") ) as $vals |
[[$keys, $vals] | transpose[] | {key:.[0],value:.[1]}] | from_entries
' <<<"$FILELIST">blobfox.json
zip blobfox.zip *.png
Loading…
Cancel
Save