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

Added 'sort' stage to CI. #392

Open
wants to merge 2 commits 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
28 changes: 28 additions & 0 deletions Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,34 @@ pipeline
}
}

stage("sort")
{
post {
failure {
githubNotify context: 'CI', description: 'publications not sorted. call make sort.', status: 'FAILURE'
}
}
steps
{
// ignore the first and last lines that only contain metainformation
sh '''#!/bin/bash
for f in publications-*.bib ; do
bibtool -q -r bibtool.rsc -i ./$f -o ./$f.result || exit 1 ; \
diff <(tail -n +2 ./$f | head -n -2) ./$f.result >> diff.result
done
if [ -s diff.result ] ; then
echo "ERROR. Publications are not sorted. Consult the README for instructions." >&2 ; \
echo "Reported issues:" >&2 ; \
cat diff.result >&2 ; \
rm *.result ; \
exit 1
else
rm *.result
fi
'''
}
}

stage("latex")
{
post {
Expand Down
12 changes: 9 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,15 +40,21 @@ $ git checkout -b my_awesome_new_publication
Please try to select the correct entry type and to fill in as much of the mandatory fields for that selection.
You can see find more information about this point in this [Wikipedia entry](https://en.wikipedia.org/wiki/BibTeX#Entry_types).
If your publication has a URL or DOI number assigned to it, then it would be nice to enter that information as we will then generate a link straight to your publication.
5. Commit your changes to your local copy of the git repository.
5. Make sure that your entry is in the correct order and your citation key conforms to our style.
This step helps us to maintain the publication list and is completely automized.
You will need [bibtool](#installing-bibtool) and only have to call
```
$ make sort
```
6. Commit your changes to your local copy of the git repository.
```
$ git commit -m "Added entry <bibtex key>"
```
6. Push the changes to your fork of this repository
7. Push the changes to your fork of this repository
```
$ git push origin my_awesome_new_publication
```
7. Setup a pull request for your addition(s) within GitHub.
8. Setup a pull request for your addition(s) within GitHub.

## Commonly used entry templates

Expand Down
2 changes: 1 addition & 1 deletion publications-2000.bib
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ @InProceedings{2000:bangerth:mesh
url = {http://www.math.colostate.edu/~bangerth/publications/2000-waves2000.pdf}
}

@TechReport{2000:bangerth:multi-threading,
@TechReport{2000:bangerth:multi-,
author = {W. Bangerth},
title = {Multi-threading support in deal.II},
institution = {IWR Heidelberg},
Expand Down