Move custom bundle
This commit is contained in:
parent
ee40679c95
commit
b903baaaf3
|
@ -1,15 +1,11 @@
|
|||
<?php
|
||||
|
||||
use App\FormatTalks\FormatTalksBundle;
|
||||
use App\FormatTalks\SculpinFormatTalksBundle;
|
||||
use FormatTalksBundle\SculpinFormatTalksBundle;
|
||||
use Opdavies\Sculpin\Bundle\ContentGeneratorBundle\SculpinContentGeneratorBundle;
|
||||
use Opdavies\Sculpin\Bundle\GistEmbedBundle\SculpinGistEmbedBundle;
|
||||
use Opdavies\Sculpin\Bundle\TwigMarkdownBundle\SculpinTwigMarkdownBundle;
|
||||
use Sculpin\Bundle\SculpinBundle\HttpKernel\AbstractKernel;
|
||||
|
||||
/**
|
||||
* Class SculpinKernel
|
||||
*/
|
||||
class SculpinKernel extends AbstractKernel
|
||||
{
|
||||
/**
|
||||
|
|
|
@ -22,7 +22,7 @@
|
|||
},
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
"App\\FormatTalks\\": "src/format-talks-bundle/src"
|
||||
"FormatTalksBundle\\": "src/FormatTalksBundle"
|
||||
}
|
||||
},
|
||||
"extra": {
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
<?php
|
||||
|
||||
namespace App\FormatTalks\DependencyInjection;
|
||||
namespace FormatTalksBundle\DependencyInjection;
|
||||
|
||||
use Symfony\Component\DependencyInjection\ContainerBuilder;
|
||||
use Symfony\Component\HttpKernel\DependencyInjection\Extension;
|
||||
|
@ -14,7 +14,7 @@ class SculpinFormatTalksExtension extends Extension
|
|||
*/
|
||||
public function load(array $configs, ContainerBuilder $container)
|
||||
{
|
||||
$loader = new YamlFileLoader($container, new FileLocator(__DIR__ . '/../../Resources/config'));
|
||||
$loader = new YamlFileLoader($container, new FileLocator(__DIR__ . '/../Resources/config'));
|
||||
$loader->load('services.yml');
|
||||
}
|
||||
}
|
5
src/FormatTalksBundle/Resources/config/services.yml
Normal file
5
src/FormatTalksBundle/Resources/config/services.yml
Normal file
|
@ -0,0 +1,5 @@
|
|||
services:
|
||||
twig.format_talks:
|
||||
class: 'FormatTalksBundle\Twig\FormatTalksExtension'
|
||||
tags:
|
||||
- { name: twig.extension }
|
|
@ -1,6 +1,6 @@
|
|||
<?php
|
||||
|
||||
namespace App\FormatTalks;
|
||||
namespace FormatTalksBundle;
|
||||
|
||||
use Symfony\Component\HttpKernel\Bundle\Bundle;
|
||||
|
|
@ -1,11 +1,8 @@
|
|||
<?php
|
||||
|
||||
namespace App\FormatTalks\Twig;
|
||||
namespace FormatTalksBundle\Twig;
|
||||
|
||||
use Twig_Extension;
|
||||
use Twig_SimpleFilter;
|
||||
|
||||
class FormatTalksExtension extends Twig_Extension
|
||||
class FormatTalksExtension extends \Twig_Extension
|
||||
{
|
||||
/**
|
||||
* {@inheritdoc}
|
||||
|
@ -13,7 +10,7 @@ class FormatTalksExtension extends Twig_Extension
|
|||
public function getFilters()
|
||||
{
|
||||
return [
|
||||
new Twig_SimpleFilter('format_talks', [$this, 'formatTalks']),
|
||||
new \Twig_SimpleFilter('format_talks', [$this, 'formatTalks']),
|
||||
];
|
||||
}
|
||||
|
|
@ -1,5 +0,0 @@
|
|||
services:
|
||||
app.twig.format_talks:
|
||||
class: 'App\FormatTalks\Twig\FormatTalksExtension'
|
||||
tags:
|
||||
- { name: twig.extension }
|
Loading…
Reference in a new issue