Initial commit of Markdown Resume

This includes several vendor libraries: Assetic, LessPHP, Mustache,
SmartyPants, Markdown
This commit is contained in:
Craig Davis
2012-03-04 10:41:18 -06:00
commit f4c52ac4c9
95 changed files with 17961 additions and 0 deletions

31
vendor/Assetic/Util/PathUtils.php vendored Executable file
View File

@@ -0,0 +1,31 @@
<?php
namespace Assetic\Util;
/**
* Path Utils.
*
* @author Johannes M. Schmitt <schmittjoh@gmail.com>
*/
abstract class PathUtils
{
public static function resolvePath($path, array $vars, array $values)
{
$map = array();
foreach ($vars as $var) {
if (false === strpos($path, '{'.$var.'}')) {
continue;
}
if (!isset($values[$var])) {
throw new \InvalidArgumentException(sprintf('The path "%s" contains the variable "%s", but was not given any value for it.', $path, $var));
}
$map['{'.$var.'}'] = $values[$var];
}
return strtr($path, $map);
}
private final function __construct() { }
}