I run my discourse instance from an rpm instead of git. that means may parts of discourse that try to find out the version from git fail in my installation. while investigating this i noticed that there is already code to load the version information from a file. But that code had a lot of duplicates. So i moved the common code into a function and then added another function to return the full git describe string.
Would this patch be acceptable?