diff --git a/config/initializers/git_info.rb b/config/initializers/git_info.rb index e7aaffdda..09b540703 100644 --- a/config/initializers/git_info.rb +++ b/config/initializers/git_info.rb @@ -2,4 +2,22 @@ # licensed under the Affero General Public License version 3 or later. See # the COPYRIGHT file. -GIT_INFO = `git show --name-only` +s = `git show --name-only 2>/dev/null || :` +if (s.nil? or s.empty?) + path = File.expand_path("config/gitversion") + begin + if (File.exists?( path)) + s = '' + f = File.open( path) + f.each_line do |line| + s += line + end + f.close + end + rescue + s = "" + end +end +GIT_INFO = s +# What's the scope of this s? Leave to GC just in case... +s = nil diff --git a/pkg/fedora/README.md b/pkg/fedora/README.md index 96c9c47d9..2dade7700 100644 --- a/pkg/fedora/README.md +++ b/pkg/fedora/README.md @@ -65,9 +65,6 @@ The topmost comment's version is patched to reflect the complete version of current specfile by 'make-dist source'. WRite the comment in this directory, copy-paste previous version nr. It will be updated. -rpmlint shows many errors, most of which related to that the server -won't start if the .git directories are not included. Needs investigation. - This has been confirmed to start up and provide basic functionality both using the thin webserver and apache passenger, and on 32/64 bit systems.