Skip to content

Instantly share code, notes, and snippets.

View itzme1on's full-sized avatar
💢

Danil itzme1on

💢
View GitHub Profile
#!/usr/bin/env bash
set -euo pipefail
need_root() {
if [[ "${EUID}" -ne 0 ]]; then
echo "Run as root. Example:"
echo " sudo curl -fsSL <url> | sudo bash"
exit 1
fi
}
@itzme1on
itzme1on / telegram-stickers-converter.sh
Last active July 12, 2024 13:13
ffmpeg command for convert all gifs in folder to webp (vp9 codec) for Telegram video stickers
#!/bin/bash
for file in *.gif; do
ffmpeg -i "$file" -c:v libvpx-vp9 -b:v 0 -crf 30 -vf "scale=512:-1,fps=30" "${file%.*}.webm"
done