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

Add bibliography ability #12

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion bin/pdsite
Original file line number Diff line number Diff line change
Expand Up @@ -119,8 +119,14 @@ function build(){

done

if [ -f ./references.bibtex ]; then
usebibliography="--bibliography $(readlink -f ./references.bibtex) --csl ${scriptpath%/*}/../ieee.csl"
else
usebibliography=""
fi

# Convert content files to context-aware HTML
find -path "$indexfileglob" -type f -execdir pandoc --template $themepath/template.html --toc -o index.html {} $localtree $localblock $configblock \; -delete
find -path "$indexfileglob" -type f -execdir pandoc $usebibliography --template $themepath/template.html --toc -o index.html {} $localtree $localblock $configblock \; -delete

# Clean up
find -path "*.tmp" -type f -delete
Expand Down
2 changes: 1 addition & 1 deletion themes/default/template.html
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@

<div class="container">
$if(title)$
<div class="page-header"><h1>$title$$if(subtitle)$<small>$subtitle$</small>$endif$</h1></div>
<div class="page-header"><h1>$title$$if(subtitle)$<p><small>$subtitle$</small></p>$endif$</h1></div>
$endif$
<div class="row">
<div class="col-md-9">
Expand Down