Open farseerfc opened 12 years ago
I encountered same problem in my environment (with Ruby 1.9.3p194).
Workaround is here and it seems to work fine for me. (only remove trailing colon)
diff --git lib/git_adapter_hooks.rb lib/git_adapter_hooks.rb
index 0288f12..deed32b 100755
--- lib/git_adapter_hooks.rb
+++ lib/git_adapter_hooks.rb
@@ -8,7 +8,7 @@ module GitHosting
@@check_hooks_installed_cached = nil
def self.check_hooks_installed
- if not @@check_hooks_installed_cached.nil? and (Time.new - @@check_hooks_installed_stamp <= 0.5):
+ if not @@check_hooks_installed_cached.nil? and (Time.new - @@check_hooks_installed_stamp <= 0.5)
return @@check_hooks_installed_cached
end
diff --git lib/git_hosting.rb lib/git_hosting.rb
index 8bcea34..adaaef8 100755
--- lib/git_hosting.rb
+++ lib/git_hosting.rb
@@ -59,7 +59,7 @@ module GitHosting
@@sudo_git_to_web_user_stamp = nil
@@sudo_git_to_web_user_cached = nil
def self.sudo_git_to_web_user
- if not @@sudo_git_to_web_user_cached.nil? and (Time.new - @@sudo_git_to_web_user_stamp <= 0.5):
+ if not @@sudo_git_to_web_user_cached.nil? and (Time.new - @@sudo_git_to_web_user_stamp <= 0.5)
return @@sudo_git_to_web_user_cached
end
logger.info "Testing if git user(\"#{git_user}\") can sudo to web user(\"#{web_user}\")"
@@ -83,7 +83,7 @@ module GitHosting
@@sudo_web_to_git_user_stamp = nil
@@sudo_web_to_git_user_cached = nil
def self.sudo_web_to_git_user
- if not @@sudo_web_to_git_user_cached.nil? and (Time.new - @@sudo_web_to_git_user_stamp <= 0.5):
+ if not @@sudo_web_to_git_user_cached.nil? and (Time.new - @@sudo_web_to_git_user_stamp <= 0.5)
return @@sudo_web_to_git_user_cached
end
logger.info "Testing if web user(\"#{web_user}\") can sudo to git user(\"#{git_user}\")"
However, I'm not ruby programmer and I don't know about backward compatibility.
Thanks, this works for me! But why it seems like python ...
I was install this in chiliproject. I typed
And it gives me:
Is this some Version Error?