1
Fork 0
mirror of https://github.com/Steffo99/config-fish.git synced 2024-10-16 14:27:34 +00:00
config-fish/functions/gen-emoji-telegram.fish

11 lines
487 B
Fish
Raw Normal View History

2024-08-21 09:45:18 +00:00
which magick --skip-functions >/dev/null 2>/dev/null
if [ $status -eq 0 ]
2024-08-21 20:07:01 +00:00
function gen-emoji-telegram --wraps=magick
2024-08-21 19:59:02 +00:00
log-t "Creating" "Telegram" "directory..."
2024-08-21 09:45:18 +00:00
command mkdir --parents "Telegram"
2024-08-21 20:42:30 +00:00
log-d "Processing" "$argv[1]" "for Telegram use..."
2024-08-21 20:07:01 +00:00
command magick -background none "$argv[1]" -resize "100x100^" -gravity center -extent 100x100 $argv[2..-1] "Telegram/$argv[1]"
2024-08-21 20:42:30 +00:00
log-t "Done! Emoji added to the" "Telegram" "directory!"
2024-08-21 09:45:18 +00:00
end
end