View Single Post
Old 11-30-2022, 03:39 PM   #2
ownedbycats
Custom User Title
ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.
 
ownedbycats's Avatar
 
Posts: 11,000
Karma: 75337983
Join Date: Oct 2018
Location: Canada
Device: Kobo Libra H2O, formerly Aura HD
I use Action Chains' single-field edit to populate a custom column, #kobopath:

Code:
program:

# Returns 'Fanfiction/Fandom' tag for fanfics
	if $$#fanficcat then
		list_re($tags, ',', '^Fanfiction.(.*)$', 'Fanfiction/\1')

# Returns 'Kobo' for Kobo store books
	elif '\[Kobo Store\]' in $#kobostatus then 'Kobo Store' 

# Returns 'PDF' for PDFs
	elif $formats == 'PDF' then
		'PDF'

# Returns 'Loans' for Loans
	elif 'Loans' in $#vls then
		'Loans'

# Returns booktype for others
	else
		$#booktype

	fi
Then fit that into the send-to-device path (see here for why I'm using a re):

Code:
{#kobopath:re(_,/)}/{author_sort:sublist(0,1,&)}/{title} - {authors}
The main thing is that I can't remember how (or if even possible) to make a GPM template output the results of a single-function template. It may be easier to make separate chains for each template-type.

Last edited by ownedbycats; 11-30-2022 at 03:47 PM.
ownedbycats is online now   Reply With Quote