Register Guidelines E-Books Search Today's Posts Mark Forums Read

Go Back   MobileRead Forums > E-Book Software > Calibre > Library Management

Notices

Reply
 
Thread Tools Search this Thread
Old 08-31-2013, 06:54 PM   #1
StevieCoops
Junior Member
StevieCoops began at the beginning.
 
Posts: 2
Karma: 10
Join Date: Aug 2013
Device: iPad
General Program Template

Can someone help me get this template into GPT format for Save to Disc

{author_sort:re(.,.,.):sublist(0,1,&)}/{series} {series_index:| [|] -} {title} ({pubdate}) /{title} - {authors}

It should remove periods at the end of Author_Sort as well as name the folder with only the first author
StevieCoops is offline   Reply With Quote
Old 09-29-2013, 10:02 PM   #2
dKodiak
Junior Member
dKodiak began at the beginning.
 
Posts: 4
Karma: 10
Join Date: Sep 2013
Device: Galaxy S4
Here is what you want... I was looking for the same thing and found it in a few different posts

{author_sort:'sublist(re($, '\.', ''),0,1,'&')'}/{series} {series_index:| [|] -} {title} ({pubdate}) /{title} - {authors:re($, '\.', '')}

Example of output

for An Oblique Approach, Belisarius series 1 by David L. Drake & Eric Flint

Drake, David L/Belisarius [1] - An Oblique Approach (pub date)/An Oblique Approach - David L Drake & Eric Flint.epub
dKodiak is offline   Reply With Quote
Old 09-30-2013, 07:24 AM   #3
chaley
"chaley", not "charley"
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: 5,898
Karma: 1216548
Join Date: Jan 2010
Location: France
Device: Many android devices
Quote:
Originally Posted by dKodiak View Post
Here is what you want... I was looking for the same thing and found it in a few different posts

{author_sort:'sublist(re($, '\.', ''),0,1,'&')'}/{series} {series_index:| [|] -} {title} ({pubdate}) /{title} - {authors:re($, '\.', '')}

Example of output

for An Oblique Approach, Belisarius series 1 by David L. Drake & Eric Flint

Drake, David L/Belisarius [1] - An Oblique Approach (pub date)/An Oblique Approach - David L Drake & Eric Flint.epub
Slight precision: the above template uses template program mode, not general program mode. In this case it is a good solution, but it wouldn't work properly if any of the function arguments were themselves template references.
chaley is offline   Reply With Quote
Old 10-01-2013, 12:02 AM   #4
StevieCoops
Junior Member
StevieCoops began at the beginning.
 
Posts: 2
Karma: 10
Join Date: Aug 2013
Device: iPad
I tried that but still got EXCEPTION: Incorrect number of arguments for function re
StevieCoops is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Date formatting/template program mode bookworm2000 Library Management 4 12-28-2012 05:41 PM
Help with template KALKITO Library Management 1 07-02-2012 03:54 PM
Does anyone use "general program mode" template functions? chaley Library Management 0 08-16-2011 12:54 PM
A little help with a save template...? Belfaborac Library Management 2 02-04-2011 10:47 PM
Kindle DX Template Gideon Calibre 6 06-02-2009 01:52 AM


All times are GMT -4. The time now is 11:03 PM.


MobileRead.com is a privately owned, operated and funded community.