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

List of Publications using BibTeX source #23

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

aminmkhan
Copy link

@aminmkhan aminmkhan commented Jan 22, 2016

Added support for including publications through BibLaTeX, based on Fancy CV template created by Adrien Friggeri.

Closes #271.

@chozelinek
Copy link

This feature would be awesome!

@johannesbottcher
Copy link
Contributor

johannesbottcher commented May 10, 2016

The bibliography part of the friggeri cv template broke with the last update of biblatex, threw lots of warnings before, and does some real strange stuff. I would advice against merging that in its current state.

Related: http://latex-community.org/forum/viewtopic.php?f=62&t=27239

@aminmkhan
Copy link
Author

Fixed the issue caused by changes in \DeclareNameFormat in biblatex (see plk/biblatex#372). This should be working fine now.

@aminmkhan aminmkhan changed the title Feature/publications biblatex List of Publications using BibTeX source May 10, 2016
Copy link

@ch3ck ch3ck left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it will make more sense if these commits are squashed into one. @aminmkhan

@thiagoveloso
Copy link

Nice addition, folks! Any idea on how to match the Publications font to the rest of the document?

@aminmkhan
Copy link
Author

@thiagoveloso You can use \setmainfont.

See https://github.com/aminmkhan/Awesome-CV/blob/6c08ff11ff1c388460d60046a1ad0c8b96b2465e/awesome-cv.cls#L202-L209

@thiagoveloso
Copy link

@aminmkhan, thank you very much. Haven't used the \setmainfont command, but the changes merged from @jckegelman made my CV's "Publications" section look much better. Help much appreciated.

@andrewcassidy
Copy link

Any way to get hyperlinks to the urls?

@aminmkhan
Copy link
Author

@andrewcassidy One quick workaround could be to use the note field in *.bib entries.

Better solution would be to play around with \DeclareFieldFormat in the class file awesome-cv.cls.

plusk01 added a commit to plusk01/awesome-cv that referenced this pull request Sep 15, 2017
@SiggiSmara
Copy link

I wanted more of the Awesome look for the bibtex entries and took a swipe at achieving that. See here for the end result:
selection_018
I don't want to tread on anyone's toes but I'm happy to share my changes. If anyone is interested then let me know and I'll see if I can figure out how to add my changes to this pull request.
Awesome job everybody!

@aminmkhan
Copy link
Author

Thanks @SiggiSmara. For now you can push your changes to a pull request similar to aminmkhan#2, and we'll see.

@SiggiSmara
Copy link

Cool @aminmkhan . Pushed the changes to you. First time for me to push from one fork to another so let me know if I managed to make a mistake along the way.

@omrysendik
Copy link

@SiggiSmara can you kindly share an example of how you create a publication entry?
Am I missing it inside @aminmkhan repository? Couldn't find it.

@SiggiSmara
Copy link

Sorry @omrysendik I missed your comment. Are you still having trouble? In the examples/cv folder you should see a bibtex file (references.bib) and a publications.tex file. The bibtex file contains the reference information itself while the publications.tex file imports the references that you want to appear.
Let me know if I can help...

@aminmkhan
Copy link
Author

@omrysendik You can check the Usage section in README here or in PR.

@syoh
Copy link

syoh commented Aug 20, 2018

Thanks for these commits. I made my publication section work based on the latest commit in this thread.

download

There is one thing I cannot figure out is how to use first initials instead of full first names. Based on some search, it seems I have to use giveninits=true somewhere. My best guess are these mods to awesome-cv.cls:

\RequirePackage[ % BibLaTeX
sorting=ydnt, % Sorts entries by year (descending order), name, title
style=verbose,
doi=false,
isbn=true,
url=false,
eprint=false,
backref = false, % include back references in bibliography
maxcitenames=3, % affects only the citations in the document body
maxbibnames=99, % affects only the bibliography, pass 99 to print all
hyperref=true,
block=none,
uniquename=init,
giveninits=true,
backend=biber % {Options: bibtex, biber}
]{biblatex}

However, the changes have completely no effect (I am using sharelatex.com). Additionally, I tried putting the options in different places; however, my publications section seems to ignore it.

How I can use first initials instead of full first names?

I would appreciate any help

@jckegelman
Copy link

@syoh the giveninits=true option is ignored because awesome-cv.cls has its own \DeclareNameFormat that uses \namepartgiven. If you always want to use initials, you can replace \namepartgiven with \namepartgiveni. If you want it to honor the giveninits option, you can use \ifgiveninits{\namepartgiveni}{\namepartgiven}

@ashwinvis
Copy link

ashwinvis commented Nov 25, 2018

@syoh Your changes look really elegant. Can you commit and push them online?

EDIT: Never mind. See aminmkhan#6

@ShanSabri
Copy link

Is there a way to format an author in bold? Also a way to number publications?

@aminmkhan
Copy link
Author

@ShanSabri You can try numerical, though there could be some issues.

You'll have to play with custom code to change formatting for the author.

@avalada
Copy link

avalada commented Jan 27, 2022

@donadviser Doesnt give me the same output as your screenshot. I dont get numbers and the journal appears in the new line. Would you mind sharing your cls file?
Thanks for your help!

@donadviser
Copy link

@avalada, can you show what it looks like?

@avalada
Copy link

avalada commented Jan 27, 2022

@donadviser
Screenshot 2022-01-27 at 8 51 45 PM

@donadviser
Copy link

@avalada Let me know if the below will fix your publications

%-------------------------------------------------------------------------------
% Bibliography
%-------------------------------------------------------------------------------
\RequirePackage[ % BibLaTeX
sorting=ydnt, % Sorts entries by year (descending order), name, title
bibstyle=numeric,
doi=false,
isbn=true,
url=false,
eprint=false,
backref = false, % include back references in bibliography
maxcitenames=3, % affects only the citations in the document body
maxbibnames=99, % affects only the bibliography, pass 99 to print all
hyperref=true,
block=none,
backend=biber % {Options: bibtex, biber}
]{biblatex}
%
%--------------------------------------------------------------
% Count total number of entries in each refsection
\AtDataInput{%
\csnumgdef{entrycount:\therefsection}{%
\csuse{entrycount:\therefsection}+1}
}

% Print the labelnumber as the total number of entries in the
% current refsection, minus the actual labelnumber, plus one
\DeclareFieldFormat{labelnumber}{\mkbibdesc{#1}}
\newrobustcmd*{\mkbibdesc}[1]{%
\number\numexpr\csuse{entrycount:\therefsection}+1-#1\relax}
%-------------------------------------------------------------

% Avoid splitting entries across page break (only for 3 or fewer lines)
% Tip: http://tex.stackexchange.com/a/51261
\AtBeginEnvironment{thebibliography}{%
\clubpenalty10000
@clubpenalty \clubpenalty
\widowpenalty10000
\interlinepenalty5000}

\DeclareBibliographyDriver{article}{%
\fontsize{10pt}{1.0em}\bodyfontlight\upshape\color{text}
\usebibmacro{bibindex}%
\newunit
\usebibmacro{begentry}%
\usebibmacro{author/translator+others}%
\setunit{\labelnamepunct}\newblock
\usebibmacro{title}%
\newunit
\newunit\newblock
\usebibmacro{byauthor}%
\newunit\newblock
\usebibmacro{bytranslator+others}%
\newunit\newblock
\printfield{version}%
\newunit\newblock%
\usebibmacro{journal+issuetitle}%
\newunit
\newunit\newblock
\usebibmacro{byeditor+others}%
\newunit
\usebibmacro{note+pages}%
\newunit\newblock
\usebibmacro{doi+eprint+url}%
\newunit\newblock
\usebibmacro{addendum+pubstate}%
\setunit{\bibpagerefpunct}\newblock
\usebibmacro{pageref}%
\usebibmacro{finentry}
\par\vspace{0.5\baselineskip}
}

@avalada
Copy link

avalada commented Jan 30, 2022

@donadviser almost! Some of the entries have an indentation as in the sceeenshot, any idea how to remove this ident? Is there also a way to set the font size of the numbering?
Screenshot 2022-01-30 at 6 50 09 PM

@aminmkhan
Copy link
Author

publication with numbering

@avalada and @donadviser That's great to see it working, if you want you can submit your changes as pull request either here, or at: https://github.com/aminmkhan/Awesome-CV/pulls

Thank you.

@OJFord
Copy link
Collaborator

OJFord commented Feb 20, 2022

Please do submit here, or update yours if merged in your repo @aminmkhan. This is a very long-standing PR but seems like an excellent addition, I do mean to review properly with a view to merging soon. Thanks.

- Generate publications section by running biber with xelatex
- Add bibliography support in cls file
- Add sample bib and tex files
@aminmkhan
Copy link
Author

Thank a lot @OJFord. I have now updated this pull request, with fresh rebase from master and squashing all commits.

Ready to review and land this! 🚀

I have moved some of the suggestions and conversations as issues to aminmkhan#11, aminmkhan#12, aminmkhan#13, aminmkhan#14, and will update in future pull requests.

@aminmkhan
Copy link
Author

Just checking @OJFord, can we proceed with the review and merging this PR? Thanks!

ljishen added a commit to ljishen/Awesome-CV that referenced this pull request Sep 28, 2022
This commit simply pulls the patch from
posquit0#23
n0k0m3 added a commit to n0k0m3/resume that referenced this pull request Jan 12, 2023
ljishen added a commit to ljishen/Awesome-CV that referenced this pull request Jan 12, 2023
This commit simply pulls the patch from
posquit0#23
@sjiang95
Copy link

Awesome work! Looking forward to being merged!

Comment on lines +113 to +114
% For publications from bibtex, add to cv/references.bib and uncomment below
% \input{cv/publications.tex}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it'd be good to have the example complete - so there's an example of rendered result, and an example of what references.bib should actually look like.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes @OJFord I wanted to update the example, but couldn't decide since it doesn't make much sense to update the main example included in preview

Also putting in fictitious bibliography entries to the awesome original creator's CV included in preview wouldn't look nice.

As an alternative, should we upload another example? e.g.

https://github.com/posquit0/Awesome-CV/blob/master/examples/resume-with-publications.pdf

@OJFord
Copy link
Collaborator

OJFord commented Jul 29, 2023

Apart from that I just want to test a couple of CVs myself and I think good to merge. 👍 Thanks!


```bash
$ xelatex {your-cv}.tex
$ biber {your-cv}

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have a small question about biber: what is the motivation to use biber instead of bibtex?
When I test this commit today (20230729), I found that the (latest after executing tlmgr update --self --all) texlive 2023 installed biber package but there is no biber binary, for which I had some troubles with this awesome feature.
Is it possible to use bibtex instead of biber cause the former is a common choice to handle bibliography?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@sjiang95 I think you can fairly easily replace the commands with bibtex locally if you are comfortable working with LaTeX. See package settings here.

backend=bibtex

biber generally has better features, you can try reading more here and here in case you are curious.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for your kind explanation. You've done an awesome job.

@sjiang95
Copy link

I have tested this pr and believe that it is ready to be merged.👍

@mbhall88
Copy link

Any news on merging this @OJFord?

@JJGabe
Copy link

JJGabe commented Apr 17, 2024

I'm not able to get the bibliography section to work for my CV. I copied the entire Bibliography section from the awesome-cv.cls of @aminmkhan into my awesome-cv.cls (I have made some other formatting edits for my own use) and then added a references.tex file, following the example, and put \addbibresource{references.bib} in the preamble of my cv.tex file. However, I am left with just the section and subsection headings; the references are not filled in (see screenshot).
BlankPubs

I'm using TeXStudio on Ubuntu 22.04 with a full and up-to-date texlive installation. The build process I'm using is xelatex -> biber -> xelatex. Any advice for this is greatly appreciated, it's the last section I need to complete.

@aminmkhan
Copy link
Author

@JJGabe you also need to include the references.bib file with some entries in BibTeX format. The examples/cv/references.bib included is empty.

@JJGabe
Copy link

JJGabe commented Apr 26, 2024

@aminmkhan Sorry, I should have been clearer. I did include my own BibTex file, which I exported from Zotero as a BetterBibTex, but I renamed it references.bib to match your template. Even when I have compiled the CV once, with the \addbibresource included, the autofill options don't show up when I start a nocite() command in the references.tex file, as they usually do with the other articles I have written.
Sample-bibtex

Sample-references

@aminmkhan
Copy link
Author

@JJGabe Not sure what's happening, perhaps cross-check that the path to bib file is correct, or check the output log of make / xelatex command for any errors.

\addbibresource{cv/references.bib}

If still not resolved, perhaps report an issue at aminmkhan/Awesome-CV/issues to follow-up. Thanks.

@JJGabe
Copy link

JJGabe commented Apr 30, 2024

@aminmkhan, thanks for the response. I made a couple of changes, including adding an extra Biber compile in my build process (xelatex -> Biber -> Biber -> xelatex) and moving the \addbibresource{} call to the awesome-cv.cls file, immediately following the \RequirePackage{biblatex} block. My references are now working, though I'm not sure which change was responsible....maybe a combination of both.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

How to add a section for Publications and References?