-
Notifications
You must be signed in to change notification settings - Fork 54
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use bibtool to format publication list. #391
Conversation
I like the idea, though I will note that that means that everyone who adds an entry also has to have bibtool installed -- this just increases the threshold for people to be able to add entries. It would be an alternative to just add this to |
It is true that it increases the threshold, but this puts again more maintenance responsibilities on our side as we will not be able to identify duplicates before merging PRs. Plus, it might still happen that we get merge conflicts of concurring PRs. This threshold is not negligible, but in my opinon very small as bibtool is practically available in repositories of any OS (even macos). |
I think Wolfgang's comment makes sense, but I am not 100% opposed to this PR.
I will need to update the docker image...
What repository on macOS are you talking about, homebrew? |
I can also remove the CI part, and we can address this in a separate PR (see #392).
Yes, I found it in homebrew but also macports. Furthermore, it is available on various linux distributions (including ubuntu and thus WSL). I can prepare a wiki entry for installing EDIT: First draft of wiki entry: bibtool.md |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OK to merge if you remove the changes to the readme.
Done. I would appreciate if we would merge this PR after #390 though. |
OK, you'll have to rebase now. |
dcc11eb
to
b6b6a22
Compare
I've added installation instructions for bibtool to the readme. If This PR is now okay to be merged from my side. |
On the weekend I looked around existing solutions to format
bib
files. I was specifically looking for tools that allow us to sort entries and generate citekeys as this would help maintaining the list. I see the following benefits:author
,title
).I found that multiple tools to sort
bib
files exist.biber
in tool-mode is capable, but translates all entries from thebibtex
to thebiblatex
format. As we want to maintain compatibility, I instead opted to use the well-establishedbibtool
(github), which was developed somewhen in the 90s and is still maintained. It is part of the ubuntu repositories as well as archlinux and possibly others.So far, I've only added the citekey generation and adjustment of indentation to the bibtool configuration to show you that bibtool really only adjusts the formatting. I want to add the sorting mechanism in a follow-up PR (or add it as a separate commit to this one).
I introduced a Makefile target
sort
so that users can easily apply the formatting. To make sure all PRs conform to the format, I've also added a newsort
stage to the CI.What is your opinion?
@tjhei -- If you agree to that mechanism, could you make sure that
bibtool
is installed on the system you run the CI on?