Restrict the number of characters (words) during Attachment Renaming

A place for users to ask each other questions, make suggestions, and discuss Bookends.
Post Reply
Dellu
Posts: 268
Joined: Sun Mar 27, 2016 5:30 am

Restrict the number of characters (words) during Attachment Renaming

Post by Dellu »

I have made Bookends to rename my files in Author Year Title format.
Here is the formatting:
Image

But, some of the articles have really long Titles; and give out really ugly file names. is there a way to restrict the number of characters so that very long Titled articles will be truncated?
(In Sente, I used to restrict it to 100 characters.)
Last edited by Dellu on Wed Mar 30, 2016 1:10 pm, edited 1 time in total.
Jon
Site Admin
Posts: 10104
Joined: Tue Jul 13, 2004 6:27 pm
Location: Bethesda, MD
Contact:

Re: Restrict the number of characters (words) during Attachment Renaming

Post by Jon »

Bookends restricts the file name to 255 characters, there is no option to make it shorter. It might not be a bad feature to add, though.

Jon
Sonny Software
Dellu
Posts: 268
Joined: Sun Mar 27, 2016 5:30 am

Re: Restrict the number of characters (words) during Attachment Renaming

Post by Dellu »

so, will you record it, or should I write it somewhere else as a feature request?
Jon
Site Admin
Posts: 10104
Joined: Tue Jul 13, 2004 6:27 pm
Location: Bethesda, MD
Contact:

Re: Restrict the number of characters (words) during Attachment Renaming

Post by Jon »

No need to file a feature request.

Jon
Sonny Software
Jon
Site Admin
Posts: 10104
Joined: Tue Jul 13, 2004 6:27 pm
Location: Bethesda, MD
Contact:

Re: Restrict the number of characters (words) during Attachment Renaming

Post by Jon »

You can set the file name limit in Bookends 12.7 beta 9 (use the Preferences -> General tab).

viewtopic.php?f=1&t=3988

Jon
Sonny Software
laxei
Posts: 10
Joined: Fri Aug 21, 2015 8:34 am

Re: Restrict the number of characters (words) during Attachment Renaming

Post by laxei »

This is nice. I'll wait for the stable release to try though.

What I've done with long title is to use short title as the primary option for file names: a d {s^t}

I also like to have clear separators between the elements: e.g. ___ (3xunderline)
Jon
Site Admin
Posts: 10104
Joined: Tue Jul 13, 2004 6:27 pm
Location: Bethesda, MD
Contact:

Re: Restrict the number of characters (words) during Attachment Renaming

Post by Jon »

The 12.7 beta is actually very stable, but you can wait, it will be released reasonably soon. As for the 3 underscores -- if I understand you correctly, that's easy, just enter them in the format you are using, e.g. a___d___t

Jon
Sonny Software
iandol
Posts: 468
Joined: Fri Jan 25, 2008 2:31 pm

Re: Restrict the number of characters (words) during Attachment Renaming

Post by iandol »

Jon, this will be a great little refinement thanks! And it is so easy to multiple select and rename all attachments automagically with this updated format, super efficient. This is maybe slightly offtopic, but is there a way to specify FIRST LAST author formatting for a PDF using the Format manager?
Jon
Site Admin
Posts: 10104
Joined: Tue Jul 13, 2004 6:27 pm
Location: Bethesda, MD
Contact:

Re: Restrict the number of characters (words) during Attachment Renaming

Post by Jon »

No. Formatting is first and foremost for bibliography generation. I've never heard of a style that outputs the first and last author and omits the middle ones.

Jon
Sonny Software
Dellu
Posts: 268
Joined: Sun Mar 27, 2016 5:30 am

Re: Restrict the number of characters (words) during Attachment Renaming

Post by Dellu »

Oh, I havn't seen this. Wonderful!
thank you
iandol
Posts: 468
Joined: Fri Jan 25, 2008 2:31 pm

Re: Restrict the number of characters (words) during Attachment Renaming

Post by iandol »

Just an update, that Jon did add an option to allow FIRST ... LAST author outputs in the format editor which works wonderfully for PDF renaming.
Jon
Site Admin
Posts: 10104
Joined: Tue Jul 13, 2004 6:27 pm
Location: Bethesda, MD
Contact:

Re: Restrict the number of characters (words) during Attachment Renaming

Post by Jon »

No, that's not an option.

Jon
Sonny Software
iandol
Posts: 468
Joined: Fri Jan 25, 2008 2:31 pm

Re: Restrict the number of characters (words) during Attachment Renaming

Post by iandol »

Hm, perhaps you misunderstood. I mean the first author and last author surnames. Here is my Rename PDF format which if you have 5 authors produces the first and last author with an ellipsis:
Screen Shot 2016-06-30 at 20.53.44.png
Screen Shot 2016-06-30 at 20.53.44.png (76.08 KiB) Viewed 8021 times
So an article like:
Roach, N. W., McGraw, P. V., & Johnston, A. (2011). Visual motion induces a forward prediction of spatial pattern. Current Biology, 21(9), 740-745. doi:10.1016/j.cub.2011.03.031
becomes a PDF named:
Roach … Johnston (2011) Visual motion induces a forward prediction of spatial pattern.pdf
Post Reply