UBports Robot Logo UBports Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Register
    • Login

    Script to convert videos for viewing on Ubuntu Touch

    Scheduled Pinned Locked Moved General
    2 Posts 2 Posters 389 Views 1 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
      Reply
      • Reply as topic
      Log in to reply
      This topic has been deleted. Only users with topic management privileges can see it.
      • BollyB Offline
        Bolly
        last edited by

        Hello I share this script to run it on the PC if anyone can use it.

        The script in this case converts all mp4 and mkv files in the folder where you run it to an Ubuntu Touch readable mp4. The script does not delete the originals, it will put them in the Converted_videos folder at the same level.

        #!/bin/bash
         
        mkdir Converted_videos
         
        for i in *.mp4
        do
            withoutExtension=$(echo "$i" | cut -f 1 -d '.')
            ffmpeg -i "$i" Converted_videos/"$withoutExtension".mp4
        done
         
        for i in *.mkv
        do
            withoutExtension=$(echo "$i" | cut -f 1 -d '.')
            ffmpeg -i "$i" Converted_videos/"$withoutExtension".mp4
        done
        

        I also share the original entry in Spanish
        https://elcondonrotodegnu.wordpress.com/2024/05/28/my-scripts-v-convertir-videos-para-poder-verlos-en-ubuntu-touch-o-en-reproductores-no-compatibles/

        15-25: BQ Aquaris E4.5 Ubuntu edition ☠️?
        23-25: BQ Aquaris E5 HD ☠️?
        16-Now (Daily use) : BQ Aquaris M10 FHD Betatester
        20-Now: PinePhone Braveheart & CE UBports

        (Family/Daily use)

        20-Now: Vollaphone Noble
        22-Now: Vollaphone22 Noble

        * 1 Reply Last reply Reply Quote 2
        • * Offline
          *Kasey009* Banned @Bolly
          last edited by

          This post is deleted!
          1 Reply Last reply Reply Quote 0

          Hello! It looks like you're interested in this conversation, but you don't have an account yet.

          Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

          With your input, this post could be even better 💗

          Register Login
          • First post
            Last post