ChiliProject is not maintained anymore. Please be advised that there will be no more updates.
We do not recommend that you setup new ChiliProject instances and we urge all existing users to migrate their data to a maintained system, e.g. Redmine. We will provide a migration script later. In the meantime, you can use the instructions by Christian Daehn.
ChiliProject::VERSION.revision doesn't capture error output (Bug #748)
My production ChiliProject install is outputting an error in my Apache logs and when I run a rake task:
fatal: Not a git repository (or any of the parent directories): .git
Turns out, this is the culprit (from the Rails console):
>> ChiliProject::VERSION.revision fatal: Not a git repository (or any of the parent directories): .git => nil
And, in lib/chili_project/version.rb, starting at line 40:
def self.revision revision = `git rev-parse HEAD` if revision.present? revision.strip[0..8] else nil end end
This doesn't manifest in development, because I'm working with a Git clone. But in production, I deploy to a clean folder, so there is no repository to read.
The output of the backtick command (git rev-parse HEAD) needs to be captured and thrown away.
[#748] Make ChiliProject::Version.revision more resilient
- Won't output errors when the ChiliProject git repo isn't there anymore,
- Works even if not invoked from the ChiliProject root directory,
- Moved the formatting logic to the git call.
Felix SchÃ¤fer wrote:
Thanks for the report. Did you use one of the packaged versions or did you "export" it from the git repository yourself?
I'm exporting from a local clone of the official repository. It's 2.5.0 with a few of our own modifications.