Skip to content

Instantly share code, notes, and snippets.

@sunil-bagde
Last active February 28, 2019 16:47
Show Gist options
  • Save sunil-bagde/3505a790a73e496d95a15246069a86c9 to your computer and use it in GitHub Desktop.
Save sunil-bagde/3505a790a73e496d95a15246069a86c9 to your computer and use it in GitHub Desktop.
$finder = new Finder;
$finder->in(resource_path('learn'))->files()->name('*.php');
foreach ($finder as $key => $file) {
$converter = new Markdownify\Converter;
file_put_contents(
$file->getBasename('.' . $file->getExtension()) . '.md',
$converter->parseString( $file->getCotent() )
);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment