From fb0631d06d8757b8de956fe97625d38528a294e2 Mon Sep 17 00:00:00 2001 From: Gawain Lynch Date: Sun, 20 Mar 2016 14:48:13 +0100 Subject: [PATCH] Remove peripheral stuff and make the extension baseline only --- composer.json | 11 +++++----- config/.gitignore | 0 config/config.yml.dist | 2 -- src/ExtensionNameExtension.php | 37 ---------------------------------- templates/.gitignore | 0 templates/extension.twig | 6 ------ web/.gitignore | 0 web/extension.css | 1 - web/extension.js | 4 ---- 9 files changed, 5 insertions(+), 56 deletions(-) create mode 100644 config/.gitignore delete mode 100644 config/config.yml.dist create mode 100644 templates/.gitignore delete mode 100644 templates/extension.twig create mode 100644 web/.gitignore delete mode 100644 web/extension.css delete mode 100644 web/extension.js diff --git a/composer.json b/composer.json index 68bb33d..44f2ea7 100644 --- a/composer.json +++ b/composer.json @@ -1,10 +1,9 @@ { - "name": "bolt/bolt-extension-starter", - "description": "A description about your extension should go here.", + "name": "", + "description": "", "type": "bolt-extension", "keywords": [ - "foo", - "bar" + "" ], "require": { "bolt/bolt": "^3.0" @@ -15,8 +14,8 @@ "license": "MIT", "authors": [ { - "name": "Your Name", - "email": "you@example.com" + "name": "", + "email": "" } ], "minimum-stability": "dev", diff --git a/config/.gitignore b/config/.gitignore new file mode 100644 index 0000000..e69de29 diff --git a/config/config.yml.dist b/config/config.yml.dist deleted file mode 100644 index 52465e7..0000000 --- a/config/config.yml.dist +++ /dev/null @@ -1,2 +0,0 @@ -# This sets the value of 'foo' to 'bar' -foo: bar diff --git a/src/ExtensionNameExtension.php b/src/ExtensionNameExtension.php index c2dca4f..814f89c 100644 --- a/src/ExtensionNameExtension.php +++ b/src/ExtensionNameExtension.php @@ -2,8 +2,6 @@ namespace Bolt\Extension\YourName\ExtensionName; -use Bolt\Asset\File\JavaScript; -use Bolt\Asset\File\Stylesheet; use Bolt\Extension\SimpleExtension; /** @@ -13,39 +11,4 @@ */ class ExtensionNameExtension extends SimpleExtension { - /** - * {@inheritdoc} - */ - protected function registerAssets() - { - // Add some web assets from the web/ directory - return [ - new Stylesheet('extension.css'), - new JavaScript('extension.js'), - ]; - } - - /** - * {@inheritdoc} - */ - protected function registerTwigFunctions() - { - return [ - 'my_twig_function' => 'myTwigFunction', - ]; - } - - /** - * The callback function when {{ my_twig_function() }} is used in a template. - * - * @return string - */ - public function myTwigFunction() - { - $context = [ - 'something' => mt_rand(), - ]; - - return $this->renderTemplate('extension.twig', $context); - } } diff --git a/templates/.gitignore b/templates/.gitignore new file mode 100644 index 0000000..e69de29 diff --git a/templates/extension.twig b/templates/extension.twig deleted file mode 100644 index e89944c..0000000 --- a/templates/extension.twig +++ /dev/null @@ -1,6 +0,0 @@ -{# - # MyExtension Twig template file - #} -
-

Your parameter is: {{ something }}

-
diff --git a/web/.gitignore b/web/.gitignore new file mode 100644 index 0000000..e69de29 diff --git a/web/extension.css b/web/extension.css deleted file mode 100644 index 9db5bc4..0000000 --- a/web/extension.css +++ /dev/null @@ -1 +0,0 @@ -/*** Put your css styles here ****/ \ No newline at end of file diff --git a/web/extension.js b/web/extension.js deleted file mode 100644 index ff46907..0000000 --- a/web/extension.js +++ /dev/null @@ -1,4 +0,0 @@ -/***** Your javascript can go below here ******/ -jQuery(document).ready(function($) { - -}); \ No newline at end of file