matteosister / GitElephant

An abstraction layer for git written in PHP
GNU Lesser General Public License v3.0
613 stars 74 forks source link

Uncaught exception 'RuntimeException', command not found #107

Closed lucaschen closed 5 years ago

lucaschen commented 7 years ago

I'm receiving this error when I'm trying to use GitElephant with PHP 5.6.10:

Fatal error: Uncaught exception 'RuntimeException' with message 'Exit code: 127 while executing: " show '-s' '--pretty=raw' '--no-color' '44f14ff'" with reason: sh: show: command not found

This is the code I'm using:

<?php
  require "vendor/autoload.php";

  use GitElephant\Repository;
  use GitElephant\Objects\Branch;
  use GitElephant\Objects\Commit;
  use GitElephant\Objects\Tag;

  $repo = new Repository('../myrepo/');

  $diff = $repo->getDiff($repo->getCommit('44f14ff'), $repo->getCommit('3948f38'));

  var_dump($diff);
GenieTim commented 6 years ago

Does this also occur if you change your code to $diff = $repo->getDiff('44f14ff', '3948f38');? Which version are you using?

GenieTim commented 5 years ago

Closing because not reproductible. And, probably outdated. Feel free to open a new issue