Jun. 27th, 2013

miriam_e: from my drawing MoonGirl (Default)
I download a lot of ebooks from Project Gutenberg, the Internet Archive, Gutenberg Australia, Cory Doctorow's craphound site, and various other places. Usually the naming of the file is not sensible. For example, the epub ebook of Jules Verne's "Journey to the Centre of the Earth" on Project Gutenberg (the version with illustrations) is titled "pg18857-images.epub". Many other sites use the old paper-book library standard of reversing an author's name as 'surname, first name' which doesn't make sense on computers. Normally I have to rename these each time, but if I'm downloading works by an author like Jules Verne who has many books it can become a little tedious.

I've written a tiny script that saves me the trouble. It uses the nice commandline program ebook-meta that comes as a part of the lovely program Calibre.

My script uses ebook-meta to extract the information to a temporary file, then uses sed to pull out the author's name (reversing it if need be) and pull out the title. Then it renames the original file as 'author - title'

I've put the little script behind the cut-tag:
Read more... )

Profile

miriam_e: from my drawing MoonGirl (Default)
miriam_e

January 2026

S M T W T F S
    1 23
45678910
11121314151617
18192021222324
25262728293031

Style Credit

Expand Cut Tags

No cut tags
Page generated Jan. 4th, 2026 08:43 pm
Powered by Dreamwidth Studios