This project modifies .bib files with the following key functionalities:
- Remove unused entries and sort: Remove unused entries and sort the remaining ones according to the citation order in a given
.auxfile. - Journal name conversion: Replace journal names with their string definitions based on IEEEfull.bib; for journals not included in IEEEfull.bib, apply word abbreviations using the ITWA file.
- Title protection: Add extra braces around citation titles to prevent BibTeX from automatically converting text to lowercase.
- Date update: Extract publication dates from local PDF files using the Everything search tool and automatically update the
yearandmonthfields of citations.
@inproceedings{gopalakrishnan2019robust,
- title={Robust wireless fingerprinting via complex-valued neural networks},
+ title={{Robust wireless fingerprinting via complex-valued neural networks}},
author={Gopalakrishnan, Soorya and Cekic, Metehan and Madhow, Upamanyu},
- booktitle={2019 IEEE Global Communications Conference (GLOBECOM)},
+ booktitle={{Proc. IEEE Global Commun. Conf. (GLOBECOM)}},
pages={1--6},
year={2019},
organization={IEEE}
}
@article{pham2016channel,
- title={Channel estimation and data detection for insufficient cyclic prefix MIMO-OFDM},
+ title={{Channel estimation and data detection for insufficient cyclic prefix MIMO-OFDM}},
author={Pham, Tri and Le-Ngoc, Tho and Woodward, Graeme K and Martin, Philippa A},
- journal={IEEE Transactions on Vehicular Technology},
+ journal=IEEE_J_VT,
volume={66},
number={6},
pages={4756--4768},
year={2016},
publisher={IEEE}
}We recommend using Conda to manage dependencies. Follow these steps to create and activate the environment:
# Create the environment
conda create -n bib_modifier python=3.12 conda-forge::pypdf2
conda activate bib_modifier
git clone https://github.com/jackdondy/bib_modifier.gitThe script optionally uses the Everything search tool to find PDF files.
- Download, install Everything, and make sure it is running.
- Download the Everything CLI, ensure the CLI executable (es.exe) is accessible in your system's PATH or specify its path in the script.
You need the following files:
-
IEEEfull.bib: A file containing IEEE journal abbreviation mappings.
-
.aux file: Generated by your LaTeX project.
-
Original BibTeX file: The reference file you want to update.
Execute the script in your terminal:
python main_with_date_check.py
Note: The blue labels in the GUI are clickable and will automatically redirect to the corresponding URLs.
Specify file paths using the Browse button:
Skip Date Check is the output path of the BibTeX file generated by this program.
Set Skip Date Check to False if you want to search local PDF files to update the year and month fields of citations.
Set ES Cmd Path to None to let the program use the system default Everything CLI path. You can test the default Everything CLI by typing es in the Windows command line.
After clicking the Save Config button, the program will generate a config.json file in the current folder, which will be automatically loaded on the next run.
If Skip Date Check is False, the Everything search tool will be invoked to locate PDF files.
When processing PDF files, if any PDF file matching the citation name is found on the system, the program will output the following prompt in the command line:
-----------------press Enter for first result / input index to select a file / a new path / month and year like '2000 jun' / 'S' to skip / 'SS' to skip all / 'DD' to auto run all:
if found any .pdf files in your system that match the citation name, or
-----------------Input new path / month and year like '2000 jun' / 'S' to skip / 'SS' to skip all / 'DD' to auto run all:
if nothing was found.
Follow the instructions to input. DD means the program auto deal with all citations, it will skip a citation if found nothing and use the first match if found any files.
The program use PyPDF2.PdfReader to read the .pdf files and search for any strings like
VOL. 11, NO. 5, 1 MARCH 2024
VOL. 16, NO. 2, FEBRUARY 2017
date of current version 16 September 2022
date of current version July 16, 2021
Note that only the first page of .pdf will be searched.
The script will generate an updated BibTeX file at the specified path (new_bib_path).
Welcome to contribute to this project, or report any issues and bugs.