original_string: public function execute()
      {
          $output = [];
          $code = 0;
  
          exec(sprintf($this->command, $this->hgPath, $this) . " 2>&1", $output, $code);
  
          if ($code != 0) {
              throw new \RuntimeException(
                  'An error occurred while using VersionControl_HG; hg returned: '
                  . implode(PHP_EOL, $output),
                  $code
              );
          }
  
          return implode(PHP_EOL, $output);
      }
code: public function execute()
      {
          $output = [];
          $code = 0;
  
          exec(sprintf($this->command, $this->hgPath, $this) . " 2>&1", $output, $code);
  
          if ($code != 0) {
              throw new \RuntimeException(
                  'An error occurred while using VersionControl_HG; hg returned: '
                  . implode(PHP_EOL, $output),
                  $code
              );
          }
  
          return implode(PHP_EOL, $output);
      }
code_tokens: public function execute ( ) { $ output = [ ] ; $ code = 0 ; exec ( sprintf ( $ this -> command , $ this -> hgPath , $ this ) . " 2>&1" , $ output , $ code ) ; if ( $ code != 0 ) { throw new \ RuntimeException ( 'An error occurred while using VersionControl_HG; hg returned: ' . implode ( PHP_EOL , $ output ) , $ code ) ; } return implode ( PHP_EOL , $ output ) ; }
docstring: Execute mercurial command.
  
  @return string
  
  @throws \RuntimeException
docstring_tokens: Execute mercurial command .