View Single Post
Old 09-15-2016, 02:17 AM   #6
chaley
Grand Sorcerer
chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.
 
Posts: 12,449
Karma: 8012886
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
Looking at calibre's code for save-to-disk, for windows the max allowed path length is 240. For linux it is 1000. In both cases calibre reserves 4 characters for the extension.

If a path is too long then (roughly) calibre shortens it by computing how many extra characters there are (X) and how many path segments there are (P), then removing X/P characters from the center of each path segment.

You can control truncation yourself using the formatter function shorten.
chaley is offline   Reply With Quote