Unable to add EPUB in Zotero 7.0.5
There are some EPUBs in my library that I am unable to add to Zotero. I have tried all manner of things including:
- Dragging and dropping the EPUB onto the Zotero menu bar icon (nothing happens)
- Using "attach" to add the file to the entry in Zotero (the file is grayed out and cannot be attached)
- Dragging and dropping the EPUB onto the parent item in Zotero (nothing happens)
Some EPUBs seem to work fine, others do not. I was having this same issue in Zotero 6. The update didn't fix it.
Thanks for your tips!
- Dragging and dropping the EPUB onto the Zotero menu bar icon (nothing happens)
- Using "attach" to add the file to the entry in Zotero (the file is grayed out and cannot be attached)
- Dragging and dropping the EPUB onto the parent item in Zotero (nothing happens)
Some EPUBs seem to work fine, others do not. I was having this same issue in Zotero 6. The update didn't fix it.
Thanks for your tips!
What a shame about Apple Books though... I have many books in there that I would like to transfer over to Zotero (and never use Apple Books again!)
var { Subprocess } = ChromeUtils.import('resource://gre/modules/Subprocess.jsm');
var { FilePicker } = ChromeUtils.importESModule('chrome://zotero/content/modules/filePicker.mjs');
var fp = new FilePicker();
fp.init(window, 'Select Directory Containing EPUBs', fp.modeGetFolder);
fp.appendFilters(fp.filterAll);
if (await fp.show() === fp.returnOK) {
let dir = fp.file;
await Subprocess.call({
command: '/bin/bash',
arguments: ['-c', `
mkdir -p "Converted"
find . -name '*.epub' -type d -maxdepth 1 |
while read epub_package; do
epub_file="$PWD/Converted/$epub_package"
cd "$epub_package"
[ -f "$epub_file" ] && continue
zip -0 -X "$epub_file" mimetype
zip -9 -X -r -u "$epub_file" *
cd ..
done
`],
workdir: dir
});
return "Success";
}
else {
return "Cancelled";
}
When the Open dialog shows, select the folder you put the Apple Books EPUBs in. Fixed copies will appear in a new subfolder called Converted. You should be able to add them to your Zotero library.
We'll support adding Apple Books EPUBs directly in the future.