Shell Tutorials

  • By
    Format Video Length in HH:MM:SS from Command Line

    In my experimentation with audio and video manipulation, I've found that most tools prefer to handle time in HH:MM:SS (hour:minute:second) format.  I always presumed that using seconds would be easier but I'm barely a novice media tool user, much less a tool creator. When I wrote the Create Short...

  • By
    Scrape Images with wget

    The desire to download all images or video on the page has been around since the beginning of the internet.  Twenty years ago I would accomplish this task with a python script I downloaded.  I then moved on to browser extensions for this task, then started...

  • By
    Allow HTTP Push with Mercurial Server

    I have always loved git but my present work at Mozilla requires me to use mercurial.  If you weren't already aware, Firefox code is managed through mercurial!  I was recently tasked with standing up a mercurial server within a docker container and ran into an issue:  mercurial rejected pushes...

  • By
    Create Short Preview from Video

    Displaying a preview image before loading a video is common practice with web media these days; oftentimes that image preview is the video's first frame or an important frame from the video.  If you've visited an adult site recently (ahem), you will have noticed that not only do you get a preview image...

  • By
    Normalize a Directory of mp3s

    Back in the early days of Napster, Kazaa, eMule, and other file sharing networks, I would download as many apps, movies, game, and movies as possible.  My illegal downloading was out of control; I would get DMCA notices from my ISP for apps and games I had...

  • By
    ding!

    I've been working with beefy virtual machines, docker containers, and build processes lately.  Believe it or not, working on projects aimed at making Mozilla developers more productive can mean executing code that can take anywhere from a minute to an hour, which in itself can hit how productive I can...

  • By
    Get and Remove EXIF Data from Photos

    If you've ever worked for an agency or a small web shop, I'd be willing to bet you've coded a fair amount of photo galleries.  You've probably also uploaded photos to social media, sent photos to friends and family, and so on.  Photos seem fairly innocent but, as is the...

  • By
    Modify Video Speed with ffmpeg

    I watch a lot of sports and recently I've become fascinated with some of the methodologies they use to illustrate events within the game.  I don't have their advanced TV software or hardware, of course, but I do have a love for ffmpeg, which allows me to do...

  • By
    Slice Videos with ffmpeg

    Isolating a specified portion of a video is a very common task for those who work within the media, probably using nice GUI tools to slice clips from the full video.  I'm a developer, however, and know how amazing ffmpeg is so I prefer to do my basic video slicing from command...

  • By
    ES6 JavaScript Minifier: babili

    The Babel toolchain is amazing.  We've used Babel to write ES6 JavaScript well before ES6 features hit browsers, we use it to parse JavaScript and write JSX, and much more.  Babel can do just about anything with the JavaScript language and I've just learned of...