<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
    <channel>
        <title>
            
                    youtubedl on
                
            
            The Neo-Babbage Files</title>
        <link>https://babbagefiles.xyz/categories/youtubedl/</link>
        <description>Recent content  in youtubedl
            on The Neo-Babbage Files</description>
        <language>en-gb</language>
        
                <managingEditor>slade@lambda-y.net (Benjamin Slade)</managingEditor>
                <webMaster>slade@lambda-y.net (Benjamin Slade)</webMaster><lastBuildDate>Mon, 29 Dec 2025 11:00:32 +0000</lastBuildDate>
        <generator>Hugo -- gohugo.io</generator>
        <docs>https://validator.w3.org/feed/docs/rss2.html</docs>
            <atom:link href="https://babbagefiles.xyz/categories/youtubedl/index.xml" rel="self" type="application/rss&#43;xml" />
        
            
            <item>
                <title>youtube-dl bash shell function: prefer mp4, and timestamp with download time</title>
                <link>https://babbagefiles.xyz/youtube-dl-mp4-downloadtime/</link>
                
                
                <description>&lt;p&gt;In case it&amp;rsquo;s useful, a quick Bash shell function which takes a single
argument (a web address that is processable by &lt;code&gt;youtube-dl&lt;/code&gt;) and
returns the best quality mp4 version (in case you need to deal with a
device that doesn&amp;rsquo;t like modern video encodings/containers), with the
&lt;strong&gt;download time&lt;/strong&gt; as the file&amp;rsquo;s modification time timestamp (useful if
you have a directory of downloaded videos and want to quickly see the
last N files you downloaded, rather than the files being sorted by
upload time).&lt;/p&gt;
&lt;p&gt;Add to your &lt;code&gt;~/.bashrc&lt;/code&gt; or other shell configuration file as appropriate:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-shell&#34; data-lang=&#34;shell&#34;&gt;youtubemp4&lt;span class=&#34;o&#34;&gt;()&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;{&lt;/span&gt;
    youtube-dl -f &lt;span class=&#34;s1&#34;&gt;&amp;#39;bestvideo[ext=mp4]+bestaudio[ext=m4a]/mp4&amp;#39;&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;&lt;/span&gt;&lt;span class=&#34;nv&#34;&gt;$1&lt;/span&gt;&lt;span class=&#34;s2&#34;&gt;&amp;#34;&lt;/span&gt;
    touch &lt;span class=&#34;s2&#34;&gt;&amp;#34;&lt;/span&gt;&lt;span class=&#34;k&#34;&gt;$(&lt;/span&gt;youtube-dl -f &lt;span class=&#34;s1&#34;&gt;&amp;#39;bestvideo[ext=mp4]+bestaudio[ext=m4a]/mp4&amp;#39;&lt;/span&gt; --get-filename &lt;span class=&#34;nv&#34;&gt;$1&lt;/span&gt;&lt;span class=&#34;k&#34;&gt;)&lt;/span&gt;&lt;span class=&#34;s2&#34;&gt;&amp;#34;&lt;/span&gt;
&lt;span class=&#34;o&#34;&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Then call in the command-line, e.g. &lt;code&gt;youtubemp4 https://www.youtube.com/watch?v=Gnnb6sjgk3A&lt;/code&gt;.&lt;/p&gt;
</description>
                
                        <author>Benjamin.Slade@fakeEmailToMakeValidatorHappy.com (Benjamin Slade)</author>
                
                     
                        
                             
                            
                                
                                 
                                    <category domain="https://babbagefiles.xyz/categories/shell">shell</category>
                                 
                                    <category domain="https://babbagefiles.xyz/categories/bash">bash</category>
                                 
                                    <category domain="https://babbagefiles.xyz/categories/youtubedl">youtubedl</category>
                                
                            
                        
                     
                        
                     
                        
                    
                
                <guid>https://babbagefiles.xyz/youtube-dl-mp4-downloadtime/</guid>
                <pubDate>Mon, 27 May 2019 22:17:00 -0500</pubDate>
            </item>
        
    </channel>
</rss>


