Betty (brown_betty) wrote,
Betty
brown_betty

Let's say you want to make a Stranger Things style christmas light-up message, but strangergif seems to be talking a half hour to load, and you realize the cockeyed.com generator doesn't make a gif, but uses sprites.

NOT A PROBLEM.

Save and run this bash script:


!#/bin/bash

foo=6take6your6meds6
for (( i=0; i<${#foo}; i++ )); do
wget -O meds$i.jpg "http://www.cockeyed.com/stranger/alphabet${foo:$i:1}.jpg"
done


Replace foo= with your message, replacing spaces with the numeral 6. I recommended putting a 6 at the front and back of your message to cause a pause.

Run the bash script.

run

convert -resize 400 -delay 40 -loop 0 `ls -v meds*` takem.gif

(convert is an imagemagick tool, you'll need that installed.)

jigger with the size and delay to get a gif you like.

potential gotchas: the spacer jpg is actually a png. Imagemagick doesn't care, and will use it correctly, but other command line processes may be confused. the strange ls -v is to cause meds1 to come before meds10, which could have been avoided with left-padding, but I didn't bother figuring that out.

This post also on dreamwidth (comment count unavailable comments)
Tags: nerdery: bash
Subscribe

  • (no subject)

    I recently saw someone on tumblr upset about a pairing because they didn't think they could be happy together, and they interpreted 'shipping' as a…

  • Did we know about this?

    </a> This post also on dreamwidth ( comments)

  • The Good Place

    So I've seen people talking about the Good Place, so I went back and caught up on it after the season ended. If you haven't seen it, there's 12…

  • Post a new comment

    Error

    Anonymous comments are disabled in this journal

    default userpic

    Your reply will be screened

    Your IP address will be recorded 

  • 0 comments