mirror of
https://github.com/there4/markdown-resume.git
synced 2024-12-03 08:59:35 -05:00
Remove legacy phar file build and update composer tooling (#63)
Simplify the build tooling: * Remove phar build, update tooling to composer * Remove legacy version tagging system * Fix incorrect readme generation
This commit is contained in:
20
build/update_readme.php
Executable file
20
build/update_readme.php
Executable file
@@ -0,0 +1,20 @@
|
||||
#!/usr/bin/env php
|
||||
<?php
|
||||
/**
|
||||
* Run the markdown resume and update the readme with the generated help
|
||||
*/
|
||||
|
||||
$baseDir = dirname(__DIR__);
|
||||
$startPoint = '## Help';
|
||||
$endPoint = '## Examples';
|
||||
$readme = file_get_contents('README.md');
|
||||
$help = shell_exec('php '.$baseDir.'/bin/md2resume list --no-interaction');
|
||||
$output = preg_replace(
|
||||
'/('.preg_quote($startPoint).')(.*)('.preg_quote($endPoint).')/si',
|
||||
"$1\n```\n" . $help . "\n```\n$3",
|
||||
$readme
|
||||
);
|
||||
|
||||
file_put_contents($baseDir.'/README.md', $output);
|
||||
|
||||
/* End of file updated_readme.php */
|
||||
Reference in New Issue
Block a user