Skip to content
Romeo Orsolino edited this page Aug 7, 2018 · 6 revisions

This is a NodeJs application to read a bibtex file and generate a formated HTML page. The file createHtml.js uses the bibtex parser in bibtexParser.js to read a bibtex file, parse it, and write an output with the desired format.

Install

You should install nodeJs. NodeJs is an event-driven I/O server-side JavaScript environment based on google's V8. On ubuntu you just can install it using apt-get

sudo apt-get update
sudo apt-get install nodejs

Then checkout the project and install the packages

https://github.com/iit-DLSLab/iit-DLSLab.github.io

You now should have a folder with all the pdfs, two javascript files (.js), and a bibtex file. The node engine can now execute the createHtml.js script and generate an html file.

  1. Check the pdf that you want to upload ================================== Make sure that the paper that will be uploaded in the website does not contain any information about the conference or the journal (we are only allowed to upload the author's original version of the paper).

  2. Add an entry to the bibtex file ================================== The bibtex file dls.bib consists of entries, which can be of the following type:

  • ARTICLE : A publication in a peer-reviewed journal. Not a conference.
  • INPROCEEDINGS: A publication which was presented on an international peer-reviewed conference, and now you can read on the proceedings of the conference.
  • CONFERENCE: A publication which was presented on a smaller conference, not necessarily peer-reviewed. You may or may not be able to read the proceedings.
  • PHDTHESIS: A PhD thesis.
  • PATENT: A patent.

The createHtml.js script will generate an html file with 5 sections, depending on the files described above. The fields may depend on the type of publication, but this things should be taken into consideration (See example below):

  • author: The authors format should be consistent. For that to happen please follow the convention {last_name1, name1 and last_name2, name2 ...}. The bibtex parser will generate an html that depends on how the bibtex is written. To be consistent, all author entries should follow the same format.
  • doi: If the paper has a doi, please insert it here.
  • url: If the paper does not have a doi but can be found on the publishers website, put the address here. Use url only if you don't have the doi.
  • The format of the name of the entry should include the last name of the principal author, the year, and journal. If the author has more than once publication on that journal on that year, just add numbers.

The script will generate the formated output, and add the following to each entry:

  • If there is a file in the papers folder with the same name as an entry, it will add the full paper link.
  • If the entry has doi or url, it will add the full paper link.

Example:

@ARTICLE{focchi16ctt,
  author="Focchi, Michele and Medrano-Cerda, Gustavo A. and Boaventura, Thiago and Frigerio, Marco and Semini, Claudio and Buchli, Jonas and Caldwell, Darwin G.",
  title="Robot impedance control and passivity analysis with inner torque and velocity feedback loops",
  journal="Control Theory and Technology",
  year="2016",
  doi="10.1007/s11768-016-5015-z"
}
  1. Execute the script ====================

To execute the script, just type:

nodejs createHtml.js dls.bib > website.html

this will execute the createHtml.js script, using the dls.bib bibtex file as input, and write the output as website.html.

Once the html file has been generated, the website must be updated and the pdf's copied to the server.

  1. Update the publications website =================================
  • Go to [the publications website]: http://old.iit.it/en/advr-dls-publications.html
  • Log in at the bottom of the page. You should have been authorized to edit the website.
  • Click the edit icon that now appears at the top on the publications list, before any text.
  • Click on the source code button, marked by the symbols <>.
  • Copy the html code generated by the script on the previous step, replacing the actual html code (pay ATTENTION on this step since there is no way to go back after you deleted the old html code!!!)
  • Search (still in html) for M. Neunert, M. Giftthaler, M. Frigerio, C. Semini, J. Buchli, Fast Derivatives of Rigid Body Dynamics for Control, Optimization and Estimation, IEEE International Conference on Simulation, Modeling and Programming for Autonomous Robots (SIMPAR), 2016 and add the following: [Winner of the Best Paper Award]. Do it between the last link of that entry (the last </a>) and the </div>

Note: The last two steps can be omitted if you just copy and paste the last entry. If you change any other entry, is better to copy and paste the whole thing since the numbering of other changes will have changed.

  1. Upload the pdf to the server =================================
  • login into the website: https://old.iit.it/administrator/
  • go to media-manager/stories/advanced-robotics/hyq-files/publications
  • in the bibtex-db repository rename the dls.bib as blsbib.txt with:
cp dls.bib dlsbib.txt
  • inside the website delete the old dlsbib.txt file and upload the new one. Then upload the pdf of the new paper (remember to upload only the original version of the paper with no header about the conference or the journal!)

Troubleshooting

  • Do not put any enter inside the bibtex file becuase this may cause some issue.
  • Pay attention to the naming convention of the paper pdf file: authorYYconference.pdf For example: "focchi17auro.pdf". The keyword of the article in the dls.bib should have the same name if you want that paper to be found and match with the corresponding pdf.
  • Remember to save the paper in the corresponding folder of the bibtex-db repo: /git/bibtex-db/papers/
  • Sometimes joomla does not respect the spacing between the words. In this case you should try to add in that location the html symbol for space which is: &nbsp;

~
~
~

Clone this wiki locally