I am trying to write a one line shell command (bash) to save a list of movies to a CSV file. I am okay with using a script if needed.
My folders are laid out as follows:
-Movies/ --A/ ----After Earth (2013).mkv --B/ ----Batman (1989).mkv
Using this command:
ls Movies/* | grep '.mkv' | cut -d. -f1
This provides me with a list of movies that I know to be of the type MKV.
12 Monkeys (1995) 2001 - A Space Odyssey (1968) A Million Ways To Die In The West (2014) A Series of Unfortionate Events (2004) Bad Company (2002)
I would eventually however like to end up with a CSV file that looks as follows:
MOVIE_NAME, MOVIE_YEAR, FILE_TYPE, CREATED_DATE (YYYY-MM-DD)
Perhaps something involving sed or awk may be necessary?