[Rivet-svn] rivet: Add BibTeX key printout to the 'show' format

Rivet Mercurial rivet at projects.hepforge.org
Mon May 22 00:00:01 BST 2017


details:   https://rivet.hepforge.org/hg/rivet/rev/312f16b77680
branches:  release-2-5-x
changeset: 5792:312f16b77680
user:      Andy Buckley <andy at insectnation.org>
date:      Sun May 21 23:50:27 2017 +0100
description:
Add BibTeX key printout to the 'show' format

diffs (31 lines):

--- a/bin/rivet	Fri May 19 12:13:02 2017 -0700
+++ b/bin/rivet	Sun May 21 23:50:27 2017 +0100
@@ -274,14 +274,10 @@
             msg += "Inspire URL: http://inspire-hep.net/search?p=find+key+" + ana.spiresId() + "\n"
             msg += "HepData URL: http://hepdata.cedar.ac.uk/view/irn" + ana.spiresId() + "\n"
 
-        if ana.experiment():
-            msg += "Experiment: " + ana.experiment()
-            if ana.collider():
-                msg += "(%s)" % ana.collider()
-            msg += "\n"
-
         if ana.year():
             msg += "Year of publication: " + ana.year() + "\n"
+        if ana.bibKey():
+            msg += "BibTeX key: " + ana.bibKey() + "\n"
 
         msg += "Authors:\n"
         for a in ana.authors():
@@ -292,6 +288,11 @@
         twrap = textwrap.TextWrapper(width=75, initial_indent=2*" ", subsequent_indent=2*" ")
         msg += twrap.fill(rivet.util.detex(ana.description())) + "\n\n"
 
+        if ana.experiment():
+            msg += "Experiment: " + ana.experiment()
+            if ana.collider():
+                msg += "(%s)" % ana.collider()
+            msg += "\n"
         # TODO: move this formatting into Analysis or a helper function?
         if ana.requiredBeams():
             def pid_to_str(pid):


More information about the Rivet-svn mailing list