Skip to content
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

Fixes bug when generating publications from single authors. #27

Merged
merged 3 commits into from Sep 30, 2018

Conversation

@tresoldi
Copy link
Contributor

tresoldi commented Sep 30, 2018

There currently is a bug when generating the author field for single-author publications: an "and" is added in front of the name of the author (as in the demo, where we have "and Einstein, Albert", see here).

This PR fixes it with with some minimal changes in _layouts/bib.html.

@alshedivat alshedivat self-requested a review Sep 30, 2018
Copy link
Owner

alshedivat left a comment

Thanks for the fix! I have no idea how I missed that dangling "and."

Your fix seems to introduce "and" between any pair of consecutive authors, not just before the last author. Not sure how I feel about it. How about we just remove "and" entirely? Thanks.

@tresoldi

This comment has been minimized.

Copy link
Contributor Author

tresoldi commented Sep 30, 2018

Oh, you are right, I missed it because I was testing only with three publications, all of them with two authors. There is surely a way to fix this, I'll take a look later.

@tresoldi

This comment has been minimized.

Copy link
Contributor Author

tresoldi commented Sep 30, 2018

I had to rewrite the Liquid loop, but I think it is fixed now. The comma is still added before the "and" (i.e., "A, B, and C", an Oxford comma), which I personally prefer, but this could be changed (the loop would get a bit more complex, but this is probably due to my lack of experience with Liquid)

{% endif %}
{% endunless %}
{% endfor %}
{% endfor %}

This comment has been minimized.

Copy link
@alshedivat

alshedivat Sep 30, 2018

Owner

Awesome, thanks! Just a minor nit: the original indentation was 2 spaces, but the new one is 4. Happy to merge once the indentation fixed. Thanks.

This comment has been minimized.

Copy link
@tresoldi

tresoldi Sep 30, 2018

Author Contributor

Sorry, the habit. Fixed now :)

@alshedivat alshedivat merged commit 488cb39 into alshedivat:master Sep 30, 2018
1 check passed
1 check passed
continuous-integration/travis-ci/pr The Travis CI build passed
Details
alshedivat added a commit that referenced this pull request Sep 30, 2018
* Fixes bug when generating publications from single authors.

* Fixes generation of author string for multiple authors

* Fixed number of spaces in indentation
 [ci skip]
jssmith1 added a commit to jssmith1/jssmith1.github.io that referenced this pull request Nov 18, 2018
…at#27)

* Fixes bug when generating publications from single authors.

* Fixes generation of author string for multiple authors

* Fixed number of spaces in indentation [ci skip]
jssmith1 added a commit to jssmith1/jssmith1.github.io that referenced this pull request Nov 18, 2018
…at#27)

* Fixes bug when generating publications from single authors.

* Fixes generation of author string for multiple authors

* Fixed number of spaces in indentation [ci skip]
SolomonMg pushed a commit to SolomonMg/SolomonMg.github.io that referenced this pull request Nov 26, 2018
…at#27)

* Fixes bug when generating publications from single authors.

* Fixes generation of author string for multiple authors

* Fixed number of spaces in indentation
 [ci skip]
bradleyethanw added a commit to bradleyethanw/bw_net that referenced this pull request Nov 26, 2018
…at#27)

* Fixes bug when generating publications from single authors.

* Fixes generation of author string for multiple authors

* Fixed number of spaces in indentation
 [ci skip]
dmfolgado added a commit to dmfolgado/dmfolgado.github.io that referenced this pull request Dec 27, 2018
…at#27)

* Fixes bug when generating publications from single authors.

* Fixes generation of author string for multiple authors

* Fixed number of spaces in indentation
 [ci skip]
dmfolgado added a commit to dmfolgado/dmfolgado.github.io that referenced this pull request Dec 27, 2018
…at#27)

* Fixes bug when generating publications from single authors.

* Fixes generation of author string for multiple authors

* Fixed number of spaces in indentation
 [ci skip]
dmfolgado added a commit to dmfolgado/dmfolgado.github.io that referenced this pull request Dec 27, 2018
…at#27)

* Fixes bug when generating publications from single authors.

* Fixes generation of author string for multiple authors

* Fixed number of spaces in indentation
 [ci skip]
ghliu added a commit to ghliu/ghliu.github.io that referenced this pull request Jan 7, 2019
…at#27)

* Fixes bug when generating publications from single authors.

* Fixes generation of author string for multiple authors

* Fixed number of spaces in indentation
 [ci skip]
g-natale pushed a commit to g-natale/al-folio that referenced this pull request Jan 17, 2019
…at#27)

* Fixes bug when generating publications from single authors.

* Fixes generation of author string for multiple authors

* Fixed number of spaces in indentation
 [ci skip]
g-natale pushed a commit to g-natale/al-folio that referenced this pull request Jan 17, 2019
…at#27)

* Fixes bug when generating publications from single authors.

* Fixes generation of author string for multiple authors

* Fixed number of spaces in indentation
 [ci skip]
gavincangan added a commit to gavincangan/gavincangan.github.io that referenced this pull request Jan 23, 2019
…at#27)

* Fixes bug when generating publications from single authors.

* Fixes generation of author string for multiple authors

* Fixed number of spaces in indentation
 [ci skip]
rohanvarma16 added a commit to rohanvarma16/website that referenced this pull request Jan 31, 2019
…at#27)

* Fixes bug when generating publications from single authors.

* Fixes generation of author string for multiple authors

* Fixed number of spaces in indentation
 [ci skip]
orionweller added a commit to orionweller/WebsiteBuilder that referenced this pull request Oct 12, 2019
Fixes bug when generating publications from single authors. (alshedivat#27)
otaviocv added a commit to otaviocv/otaviocv.github.io that referenced this pull request Dec 8, 2019
…source

* 'master' of https://github.com/alshedivat/al-folio: (38 commits)
  Make google analytics conditional (alshedivat#63)
  Enable preview images on social media (alshedivat#66)
  Add social buttons: Publons, ResearchGate and Blogger (alshedivat#65)
  Make the display of an email conditional
  Include link and pdf in bib
  Added css to take account of vertical scroll bar and avoid content jumps
  Update _config.yml
  Added quora and medium to social
  move image-row height and col to media queries to adjust with viewport
  Fixes bug when generating publications from single authors. (alshedivat#27)
  Do not delete CNAME when moving _site files to deploy branch (alshedivat#25)
  Minor formatting
  Add Travis CI (alshedivat#21)
  Changed `baseurl` property of `_config.yml` back to /al-folio and minor edit to `README` for consistency with the al-folio master branch
  Fixed webkit text scaling `bug`
  Removed profile align property completely
  Added left class to all images
  Removed align:left from col class
  Removed !important flag from profile class alignment
  Bump license year to 2018
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.