17 Mayıs 2012

Rubymine Unsupported Git Error on MacOSX Lion Solution

Solution for the "Unsupported format of git --version output: git version 1.7.7.5 (Apple Git-26)" problem:

The problem is the last part of "git version" output, which is "(Apple Git-26)" as mentioned at Jetbrain's issue tracking system. But the solution given as a simple script did not work for me as the if conditional never returned true.

I'm not a bash scripting expert but my workaround was defining a variable to hold the parameter "--version". Otherwise the if conditional never seemed to work for me.

Here is my modified script:

##!/bin/sh
volkan="--version"
if [ $1 = $volkan ]; then
  echo `git version` | awk 'BEGIN {FS="("} {print $1}'
else
  git "$@"
fi



Hiç yorum yok: