text: 
  #include <php.h>
  #include <git2.h>
  
  #include "php_git2_internal.h"
  
  PHP_FUNCTION(git_repository_path)
  {
      const char *path;
      zend_result zendParse;
      zval *zrepository;
      struct php_git2_repository *repository;
      zend_class_entry *ceRepository;
  
      path = NULL;
      zendParse = 0;
      zrepository = NULL;
      repository = NULL;
      ceRepository = php_git2_get_repository_ce();
      zendParse = zend_parse_parameters(ZEND_NUM_ARGS(), "O", \
              &zrepository, ceRepository);
      if (zendParse != SUCCESS)
          RETURN_THROWS();
      repository = gitrep_fetch_object(Z_OBJ_P(zrepository));
      path = git_repository_path(repository->s);
      RETURN_STRING(path);
  }
  
  