Skip to content
Extraits de code Groupes Projets
Valider 8b3336d9 rédigé par Tigriz's avatar Tigriz
Parcourir les fichiers

Update matrixpack.sh for gifs

parent 8474e27e
Aucune branche associée trouvée
Aucune étiquette associée trouvée
Aucune requête de fusion associée trouvée
......@@ -53,8 +53,8 @@ do
if [ -f "$f" ]; then
# Resizing large images
width=$(identify -format "%w" "$f")> /dev/null
height=$(identify -format "%h" "$f")> /dev/null
width=$(identify -format "%w" "$f"[0])> /dev/null
height=$(identify -format "%h" "$f"[0])> /dev/null
if [ $width -gt 256 ]; then
width="256";
fi
......@@ -90,8 +90,8 @@ do
# Calculating 128x128> format
convert "$slug/tmp/$f.$type" -resize "128x128" "$slug/tmp/size"
width=$(identify -format "%w" "$slug/tmp/size")> /dev/null
height=$(identify -format "%h" "$slug/tmp/size")> /dev/null
width=$(identify -format "%w" "$slug/tmp/size"[0])> /dev/null
height=$(identify -format "%h" "$slug/tmp/size"[0])> /dev/null
# Appending to json
echo -n "{\"body\":\"$f\",\"info\":{\"mimetype\":\"image/$type\",\"h\":$height,\"w\":$width,\"thumbnail_url\":\"$mxc\"},\"msgtype\":\"m.sticker\",\"url\":\"$mxc\",\"id\":\"$packname-$f\"}" >> "$slug/$slug.json"
first=","
......
0% Chargement en cours ou .
You are about to add 0 people to the discussion. Proceed with caution.
Veuillez vous inscrire ou vous pour commenter