{"id":2631,"date":"2016-01-23T11:32:09","date_gmt":"2016-01-23T09:32:09","guid":{"rendered":"http:\/\/www.final-memory.org\/?page_id=2631"},"modified":"2023-04-16T17:47:33","modified_gmt":"2023-04-16T15:47:33","slug":"tips-und-tricks-mit-der-gnulinux-kommandozeile","status":"publish","type":"page","link":"https:\/\/www.final-memory.org\/?page_id=2631","title":{"rendered":"Tips und Tricks mit der GNU\/Linux Kommandozeile"},"content":{"rendered":"<p>Hier sammele ich n\u00fctzliche Kommandozeilen, die man ab und an braucht, aber schnell wieder vergisst.<\/p>\n<h3>Audio einer Videodatei mit ffmpeg und lame extrahieren<\/h3>\n<p><code>$ ffmpeg -i video.mp4 -vn -f wav - | lame -V 3 - audio.mp3<\/code><\/p>\n<h3>Finde die 10 gr\u00f6\u00dften Dateien und Verzeichnisse<\/h3>\n<p><code>$ du -hsx * | sort -rh | head -10<\/code><\/p>\n<p>Die Ausgabe sieht dann ungef\u00e4hr so aus:<\/p>\n<p><code><br \/>\nmarndt@jll:~\/tmp$ du -hsx * | sort -rh | head -10<br \/>\n31M\tfs-uae-launcher-2.6.2<br \/>\n180K\tMenu.pdf<br \/>\n8,0K\tWarenkorb.csv<\/code><\/p>\n<h3>Finde die 10 gr\u00f6\u00dften Dateien in einem baum<\/h3>\n<p><code>$ find . -type f -printf \"%s\\t%p\\n\" | sort -n | tail -10 | sort -n -r<\/code><\/p>\n<p>Die Ausgabe sieht dann ungef\u00e4hr so aus:<\/p>\n<p><code>marndt@jll:~\/Graphics\/Atari$ find . -type f -printf \"%s\\t%p\\n\" | sort -n | tail -10 | sort -n -r<br \/>\n951127\t.\/ST Offline Tournament\/Thorn_Paradroid90_5075.png<br \/>\n737280\t.\/Oxyron Party 2008\/oxyron2008.st<br \/>\n737280\t.\/Oxyron Party 2008\/oxyboot.st<br \/>\n683087\t.\/headphones_girl_music_anime_desktop_1600x1200_free-wallpaper-3057.jpg<br \/>\n629274\t.\/Regnum Aeternum\/windmill1.jpg<br \/>\n243249\t.\/Fonts\/3121603487_c8a8e69e9c_o.png<br \/>\n242510\t.\/atari_wallpaper2_531.jpg<br \/>\n200710\t.\/Gemulator with ISA card.jpg<br \/>\n178861\t.\/cx78.jpg<br \/>\n153770\t.\/ST Offline Tournament\/ssb_ChaosEngine_1785.jpg<\/code><\/p>\n<p>&nbsp;<\/p>\n<h3>Sammele Dateien in verschiedenen Verzeichnissen in einem Zielverzeichnis<\/h3>\n<p><code>$ find . -name \"*.mobi\" -print0 | xargs -r0 mv -t ~\/tmp\/<\/code><\/p>\n<h3>Bilder auf Mindestgr\u00f6\u00dfe verkleinern oder vergr\u00f6\u00dfern<\/h3>\n<p><code>$ convert -resize ${SIZE}x${SIZE}^ \"$file\" temp.png<\/code><\/p>\n<h3>Manual page als Textdatei umformatieren<\/h3>\n<p>Am Beispiel des Programmes &#8220;zip&#8221;<\/p>\n<p><code>$ man zip | col -b &gt; zip.txt<\/code><\/p>\n<h3>CD-Images .bin\/.cue nach .iso konvertieren<\/h3>\n<p>Das geht mit dem Programm &#8220;ccd2iso&#8221;, unter Ubuntu installierbar.<br \/>\n<code>$ ccd2iso cdimage.bin cdimage.iso<\/code><\/p>\n<div id=\"facebook_like\"><iframe src=\"http:\/\/www.facebook.com\/plugins\/like.php?href=https%3A%2F%2Fwww.final-memory.org%2F%3Fpage_id%3D2631&amp;layout=standard&amp;show_faces=true&amp;width=500&amp;action=like&amp;font=segoe+ui&amp;colorscheme=light&amp;height=80\" scrolling=\"no\" frameborder=\"0\" style=\"border:none; overflow:hidden; width:500px; height:80px;\" allowTransparency=\"true\"><\/iframe><\/div>","protected":false},"excerpt":{"rendered":"<p>Hier sammele ich n\u00fctzliche Kommandozeilen, die man ab und an braucht, aber schnell wieder vergisst. Audio einer Videodatei mit ffmpeg und lame extrahieren $ ffmpeg -i video.mp4 -vn -f wav &#8211; | lame -V 3 &#8211; audio.mp3 Finde die 10 gr\u00f6\u00dften Dateien und Verzeichnisse $ du -hsx * | sort -rh | head -10 Die &hellip; <a href=\"https:\/\/www.final-memory.org\/?page_id=2631\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;Tips und Tricks mit der GNU\/Linux Kommandozeile&#8221;<\/span><\/a><\/p>\n","protected":false},"author":2,"featured_media":0,"parent":79,"menu_order":0,"comment_status":"open","ping_status":"open","template":"","meta":{"footnotes":""},"class_list":["post-2631","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/www.final-memory.org\/index.php?rest_route=\/wp\/v2\/pages\/2631","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.final-memory.org\/index.php?rest_route=\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/www.final-memory.org\/index.php?rest_route=\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/www.final-memory.org\/index.php?rest_route=\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.final-memory.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=2631"}],"version-history":[{"count":12,"href":"https:\/\/www.final-memory.org\/index.php?rest_route=\/wp\/v2\/pages\/2631\/revisions"}],"predecessor-version":[{"id":2866,"href":"https:\/\/www.final-memory.org\/index.php?rest_route=\/wp\/v2\/pages\/2631\/revisions\/2866"}],"up":[{"embeddable":true,"href":"https:\/\/www.final-memory.org\/index.php?rest_route=\/wp\/v2\/pages\/79"}],"wp:attachment":[{"href":"https:\/\/www.final-memory.org\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=2631"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}