# Firefox plugin download full file and format it's name

**URL:** <https://discourse.jabref.org/t/firefox-plugin-download-full-file-and-format-its-name/2053>\
**Category:** Help\
**Created:** [April 30, 2020, 12:48pm UTC](https://discourse.jabref.org/t/firefox-plugin-download-full-file-and-format-its-name/2053 "2020-04-30T12:48:26Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![btut](https://yyz2.discourse-cdn.com/flex030/user_avatar/discourse.jabref.org/btut/32/1018_2.png) [@btut](https://discourse.jabref.org/u/btut)\
**Post date:** [April 30, 2020, 12:48pm UTC](https://discourse.jabref.org/t/firefox-plugin-download-full-file-and-format-its-name/2053/1 "2020-04-30T12:48:27Z")

</div>

Hi,  
I started using the firefox plugin recently as I finally got JabRef 5 running on my linux machine.  
What I noticed was that instead of downloading the full pdf, it just sets a link. Is there an option to download the full file should one be available?  
I now resorted to adding with the plugin and then looking for the fulltext pdf from JabRef. However, I would like to have the filename formatted in a very special way. Seems like this was possible with earlier versions, as described [here](https://discourse.jabref.org/t/is-it-possible-to-customize-the-name-of-downloaded-file-when-i-use-look-up-full-text-document/60/2), but those strings do not work with JabRef 5. Is there any documentation on how the strings should look?  
This formatter:  
`[bibtexkey]_\begin{title}\format[FormatChars,RemoveBrackets]{\title}\end{title}`  
for example results in the bibtexkey (as wanted) and then  
`_begin_title_format_title_end_title`  
I just tried that string as it was supposedly working at some point, I actually would like to have the bibtexkey followed by an underscore and then the title, with all non-letter characters replaced by an underscore and all whitespaces replaced by a dot. Is that possible?

---

<div class="post-metadata">

**Author:** ![btut](https://yyz2.discourse-cdn.com/flex030/user_avatar/discourse.jabref.org/btut/32/1018_2.png) [@btut](https://discourse.jabref.org/u/btut)\
**Post date:** [April 30, 2020, 1:14pm UTC](https://discourse.jabref.org/t/firefox-plugin-download-full-file-and-format-its-name/2053/2 "2020-04-30T13:14:07Z")

</div>

Aha, formatting was changed to how bibtexkeys are formatted (see [here](https://docs.jabref.org/setup/bibtexkeypatterns))  
However, I still have to find out how replace works here. I still don’t understand how the regex replace works here.

---

<div class="post-metadata">

**Author:** ![btut](https://yyz2.discourse-cdn.com/flex030/user_avatar/discourse.jabref.org/btut/32/1018_2.png) [@btut](https://discourse.jabref.org/u/btut)\
**Post date:** [April 30, 2020, 2:09pm UTC](https://discourse.jabref.org/t/firefox-plugin-download-full-file-and-format-its-name/2053/3 "2020-04-30T14:09:34Z")

</div>

This is my format string now:  
`[bibtexkey]_[title:regex(":","_"):regex("/","_"):regex("-","_"):regex(" ",".")]`  
It does not catch all non-alphanumerical characters as I wanted, but using \W crashes the application and so does trying to escape the dot for example. I will stick with this one as it will cover most cases.  
However, it would still be nice to get the plugin to automatically download pdf files…

---

<div class="post-metadata">

**Author:** ![btut](https://yyz2.discourse-cdn.com/flex030/user_avatar/discourse.jabref.org/btut/32/1018_2.png) [@btut](https://discourse.jabref.org/u/btut)\
**Post date:** [April 30, 2020, 2:21pm UTC](https://discourse.jabref.org/t/firefox-plugin-download-full-file-and-format-its-name/2053/4 "2020-04-30T14:21:38Z")

</div>

Looks like automatic download is not supported yet, but someone is working on it.

> <https://github.com/JabRef/jabref/issues/5662>
>
> Is your suggestion for improvement related to a problem? Please describe.
> Usually, when importing entries using the browser extension, they include urls...

---

<div class="post-metadata">

**Author:** ![btut](https://yyz2.discourse-cdn.com/flex030/user_avatar/discourse.jabref.org/btut/32/1018_2.png) [@btut](https://discourse.jabref.org/u/btut)\
**Post date:** [April 30, 2020, 4:44pm UTC](https://discourse.jabref.org/t/firefox-plugin-download-full-file-and-format-its-name/2053/5 "2020-04-30T16:44:06Z")

</div>

I started to work on the issue myself and drafted an implementation. Check it out [here](https://github.com/JabRef/jabref/issues/5662)!
