Last active
August 29, 2015 13:59
-
-
Save dhargitai/10727409 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Convert m4a to mp3 | |
ffmpeg -i audioFile.m4a -codec:v copy -codec:a libmp3lame -q:a 2 audioFile.m4a.mp3 | |
# Download extracted audio content from youtube video | |
youtube-dl -x "Youtube-link" | |
# Find and replace "Oldcontent" to "Newcontent" in FILENAME | |
sed -i.bak s%Oldcontent%Newcontent%g FILENAME | |
# Replace a word with another in all file under a directory structure | |
find ./ -type f -exec sed -i s%Oldcontent%Newcontent% {} + | |
# Replace part of the directory and filenames on all files and directory under a directory | |
find . -depth -name '*Oldnamepart*' -execdir bash -c 'for f; do mv -i "$f" "${f//Oldnamepart/Newnamepart}"; done' bash {} + | |
# Find the last modified file under a directory structure | |
find . -type f -printf '%T@ %p\n' | sort -n | tail -1 | cut -f2- -d" " |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment