Skip to content

Commit

Permalink
Bibliography: make author family names appear last (#4506)
Browse files Browse the repository at this point in the history
* bib-formatting

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Rename bib style class

* Delete unused imports

* Add comments to conf.py

* Tweaks to .bib files

* Add pybtex to Doc requirements

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* comment out 'lastfirst'

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
  • Loading branch information
eebasso and pre-commit-ci[bot] authored Dec 15, 2023
1 parent af00348 commit 262895b
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions Docs/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -70,12 +70,12 @@
# BaseStyle class in pybtex/style/formatting/__init__.py
# UnsrtStyle class in pybtex/style/formating/unsrt.py
class WarpXBibStyle(UnsrtStyle):
# We want the family name, i.e, "last" name, of an author to appear first.
default_name_style = 'lastfirst'
# This option makes the family name, i.e, "last" name, of an author to appear first.
# default_name_style = 'lastfirst'

def __init__(self, *args, **kwargs):
# We want the given names of an author to be abbreviated to just initials.
# Example: "Jean-Luc Vay" becomes "Vay, J.-L."
# This option makes the given names of an author abbreviated to just initials.
# Example: "Jean-Luc" becomes "J.-L."
# Set 'abbreviate_names' to True before calling the superclass (BaseStyle class) initializer
kwargs['abbreviate_names'] = True
super().__init__(*args, **kwargs)
Expand Down

0 comments on commit 262895b

Please sign in to comment.