I have a variable which has the directory path, along with the file name. I want to extract the filename alone from the Unix directory path and store it in a variable.
dirname "/usr/home/theconjuring/music/song.mp3" will yield /usr/home/theconjuring/music.
dirname "/usr/home/theconjuring/music/song.mp3"
/usr/home/theconjuring/music