git-php icon indicating copy to clipboard operation
git-php copied to clipboard

remove --end-of-options option for git version < 2.24

Open mrsad opened this issue 2 years ago • 1 comments

mrsad avatar Oct 03 '22 02:10 mrsad

Hello,

I thought about it and I don't want this directly in CliRunner. What about new Runner implementation?

class OldGitRunner extends CliRunner
{
	public function run($cwd, array $args, array $env = NULL)
	{
		if (($key = array_search('--end-of-options', $args)) !== FALSE) {
			unset($args[$key]);
		}

		parent::run($cwd, $args, $env);
	}
}

$git = new CzProject\GitPhp\Git(new CzProject\GitPhp\Runners\OldGitRunner);

janpecha avatar Oct 05 '22 07:10 janpecha

Implemented as bb195e30442bc5206b30fa9a304e20ea8e96458f

janpecha avatar Dec 10 '22 18:12 janpecha