1

Related to this question, is there a best place to store version information so it is accessible within Play 2 project and not duplicated? We have multiple application.conf files (each developer has one) so that's not a great place for version information for us. Also the SBT buildInfo plugin seems like overkill for a simple version number.

A comment at the end of the linked question says to store version info in Global.java, then it will be accessible in your play app (such as to display in your footer). Can you then ignore program name/version in Build.scala and just maintain your actual name/version in Global.java?

Community
  • 1
  • 1
xref
  • 1,707
  • 5
  • 19
  • 41

1 Answers1

4

Use the application.conf and include it in your developer conf files with include "application.conf" on the very first line.

Marius Soutier
  • 11,184
  • 1
  • 38
  • 48
  • This is the route I went, made a constants.conf file and included it as you mentioned. I'm sure we'll need a few other constants in the future that don't belong in the entities etc. Thanks! – xref Jan 16 '13 at 16:37