From b12ebb98d3ef9880eb4db3e49b31cad8a457c81d Mon Sep 17 00:00:00 2001 From: cyberalien Date: Tue, 14 Mar 2017 12:23:13 +0200 Subject: [PATCH] PHP script to locate build directory. See simple-svg-cdn package --- build/Scripts.php | 26 ++++++++++++++++++++++++++ composer.json | 7 ++++++- 2 files changed, 32 insertions(+), 1 deletion(-) create mode 100644 build/Scripts.php diff --git a/build/Scripts.php b/build/Scripts.php new file mode 100644 index 0000000..09248f8 --- /dev/null +++ b/build/Scripts.php @@ -0,0 +1,26 @@ + + * + * For the full copyright and license information, please view the license.txt + * file that was distributed with this source code. + * @license MIT + */ + +namespace SimpleSVG\SimpleSVG; + +class Scripts +{ + /** + * Return path to dist directory to create custom builds in PHP + * + * @return string + */ + public static function dist() + { + return dirname(dirname(__FILE__)) . '/dist'; + } +} diff --git a/composer.json b/composer.json index 4597306..da5c1ea 100644 --- a/composer.json +++ b/composer.json @@ -4,5 +4,10 @@ "author": "Vjacheslav Trushkin (artodia.com)", "type": "library", "license": "MIT", - "homepage": "https://simplesvg.com/" + "homepage": "https://simplesvg.com/", + "autoload": { + "psr-4": { + "SimpleSVG\\SimpleSVG\\": "build" + } + } }