![]() |
#1 |
Guru
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 681
Karma: 929286
Join Date: Apr 2014
Device: PW-3, iPad, Android phone
|
Extracting files from ePub on iPad/iMac
I've got a Mac-centric client that I make ePubs for.
It would be useful if he could extract the html files and images for his website as he needs them. I could do it for him, but is there a simple way he can do this on an iPad or iMac? I know how fussy Macs are about filetypes so I don't know if an unzipper would work easily. I guess Sigil or Calibre would work, but I'd rather not complicate things. |
![]() |
![]() |
![]() |
#2 |
Ex-Helpdesk Junkie
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 19,421
Karma: 85400180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
|
Rename the *.epub to *.zip and you can use any unzipper to open it up.
Some unzippers don't like the renamed file -- it's not just Mac, Linux's file-roller program (part of Gnome) at least used to choke on it for no good reason. But the command-line `unzip` utility can definitely handle any file extension whatsoever. |
![]() |
![]() |
![]() |
#3 | |
Guru
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 681
Karma: 929286
Join Date: Apr 2014
Device: PW-3, iPad, Android phone
|
Quote:
Ideally I was hoping for an unzipper that will work regardless of nominal filetype. |
|
![]() |
![]() |
![]() |
#4 | ||
Grand Sorcerer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 5,680
Karma: 23983815
Join Date: Dec 2010
Device: Kindle PW2
|
Quote:
Tell your client to try the following: Quote:
|
||
![]() |
![]() |
![]() |
#5 | |
Ex-Helpdesk Junkie
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 19,421
Karma: 85400180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
|
Quote:
But changing fixing a filetype really is as easy as renaming it -- an EPUB is a renamed ZIP to begin with, so renaming it back ensures that applications will recognize it as a ZIP. And as I said, the command-line unzip utility can handle arbitrary filenames. You could also use pdurrant's ePub Zip/Unzip AppleScript application for Mac OS X. It is a drag-and-drop AppleScript which simply acts as a wrapper around `unzip`. Last edited by eschwartz; 05-05-2016 at 10:05 AM. |
|
![]() |
![]() |
![]() |
#6 | |
Well trained by Cats
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 30,897
Karma: 60358908
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
|
Quote:
![]() Oh! Right! MAC ![]() "Simple enough, even a Manager can use one" -- Me (1988) e-book viewer (the Calibre CLI tool) allows copy (and paste...someplace else ![]() |
|
![]() |
![]() |
![]() |
#7 |
Connoisseur
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 66
Karma: 12538
Join Date: Oct 2011
Device: Kobo Wifi, Kobo Glo HD
|
Fwiw, unzip works just fine on .epub files from the Terminal. But that would be *scary*.
![]() |
![]() |
![]() |
![]() |
#8 | |
Guru
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 681
Karma: 929286
Join Date: Apr 2014
Device: PW-3, iPad, Android phone
|
Quote:
|
|
![]() |
![]() |
![]() |
#9 |
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,613
Karma: 6718541
Join Date: Dec 2004
Location: Paradise (Key West, FL)
Device: Current:Surface Go & Kindle 3 - Retired: DellV8p, Clie UX50, ...
|
Not the case if you modify eschwartz' method slightly.
Simply make a copy of the ePub first and change the extension on the copy only. Unzip the copy, extract the needed images, and delete the copy and left over extracted contents. That way there is no need to reassemble the ePub afterward. |
![]() |
![]() |
![]() |
#10 |
null operator (he/him)
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 21,616
Karma: 29710338
Join Date: Mar 2012
Location: Sydney Australia
Device: none
|
@AlanHK - Assuming the epub is not ridiculously large and your client knows how to unpack a zip archive on his/her Mac, why not send two files, 'whatever.epub' and 'what's-in-whatever.zip'. The fact that the second is a rebadged copy of the first is hardly likely to be here or there. It would also deter your client from tinkering with the epub - a'la Hitch's recent 'Anyone here ever seen..." thread.
You could even remove the components that make it an epub -- mimetype, opf etc --- from the zip. BR Last edited by BetterRed; 05-05-2016 at 09:18 PM. |
![]() |
![]() |
![]() |
#11 | |
Bookmaker & Cat Slave
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 11,503
Karma: 158448243
Join Date: Apr 2010
Location: Phoenix, AZ
Device: K2, iPad, KFire, PPW, Voyage, NookColor. 2 Droid, Oasis, Boox Note2
|
Quote:
Hitch |
|
![]() |
![]() |
![]() |
#12 | |
Guru
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 681
Karma: 929286
Join Date: Apr 2014
Device: PW-3, iPad, Android phone
|
Quote:
Especially as it's predicated by you clearly not bothering to read my initial post, which explained exactly what I wanted to do and why. Find something better to do than skimming old threads to look for opportunities to inject unhelpful sneering remarks. |
|
![]() |
![]() |
![]() |
#13 | ||
Bookmaker & Cat Slave
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 11,503
Karma: 158448243
Join Date: Apr 2010
Location: Phoenix, AZ
Device: K2, iPad, KFire, PPW, Voyage, NookColor. 2 Droid, Oasis, Boox Note2
|
Quote:
NOR did I particularly think that a thread started 5 days ago was "old." I deal with excruciatingly non-tech clients all day long. YES, I would by far rather that they manage their needs themselves, but half the time, no matter how much I try to foster independence, for their own sakes, not mine, it almost inevitably ends up causing more grief than it saves and twice the time. I read your initial post, and eschwartz' response to you, AND this line, particularly: Quote:
I'm surprised that he can't copy an ePUB on a Mac, and change the file extension. Yes, I know that many Mac users don't display file extensions, and thus don't understand them, but this is rote stuff. One simple Screencast, saying "copy this, change that, and unzip it," and I'd think it would solve the issues. OR, as suggested elsewhere, send him both. Of course--obviously--you know your client best. If it's too much for him, it's too much. I'll simply point out that several different flavors of browser will, fairly routinely, save down an ePUB as a zipped archive. I know that Exploder does it, and I've been told, but not witnessed first-hand, that Safari will. That's one of the thoughts that I had, when asking what I thought was a perfectly reasonable question: WHY? But, as you patently have all the feedback you want now, I'll leave you to it. ![]() Hitch |
||
![]() |
![]() |