Skip to content

Commit

Permalink
ZF2-58 Classmap generator broken on Win32
Browse files Browse the repository at this point in the history
  • Loading branch information
Thinkscape committed Sep 2, 2011
1 parent e10ae0f commit 8201803
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions bin/classmap_generator.php
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@
$libraryPath = '';
if (isset($opts->l)) {
$libraryPath = $opts->l;
$libraryPath = rtrim($libraryPath, '/\\') . '/';
$libraryPath = rtrim($libraryPath, '/\\') . DIRECTORY_SEPARATOR;
if (!is_dir($libraryPath)) {
echo "Invalid library directory provided" . PHP_EOL . PHP_EOL;
echo $opts->getUsageMessage();
Expand Down Expand Up @@ -134,7 +134,7 @@
iterator_apply($l, function() use ($l, $map, $strip, $libraryPath){
$file = $l->current();
$namespace = empty($file->namespace) ? '' : $file->namespace . '\\';
$filename = str_replace($strip, '', $file->getPath() . '/' . $file->getFilename());
$filename = str_replace($strip, '', $file->getPath() . DIRECTORY_SEPARATOR . $file->getFilename());

// Add in relative path to library
$filename = $libraryPath . $filename;
Expand Down

0 comments on commit 8201803

Please sign in to comment.