FlamingTempura / bibtex-tidy

Cleaner and Formatter for BibTeX files
https://flamingtempura.github.io/bibtex-tidy/
MIT License
832 stars 63 forks source link

Escaping in URL/DOI/... can invalidate link #431

Closed jdujava closed 4 months ago

jdujava commented 4 months ago

Following entry

@article{HelloWorld,
    title         = {{Foo}},
    journal       = {bar},
    url           = {https://www.rcsb.org/structure/AF_AFQ14008F1},
}

is formatted to

@article{HelloWorld,
    title         = {{Foo}},
    journal       = {bar},
    url           = {https://www.rcsb.org/structure/AF\_AFQ14008F1},
}

from which LaTeX creates malformed link https://www.rcsb.org/structure/AF%5C_AFQ14008F1, which doesn't work properly.

Same behaviour applies to DOI and similar fields. Is it possible to enable character escaping only in title/author fields?

jdujava commented 4 months ago

Only now I noticed that this is duplicate of #415. Closing in favor of it.