Skip to content
This repository was archived by the owner on Nov 27, 2020. It is now read-only.

Commit 693e1f7

Browse files
committed
moved to the 3.0 directory structure
1 parent 4a86c13 commit 693e1f7

File tree

14 files changed

+186
-88
lines changed

14 files changed

+186
-88
lines changed

.gitignore

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,10 @@
1-
/web/bundles/
2-
/app/bootstrap.php.cache
3-
/app/cache/*
41
/app/config/parameters.yml
5-
/app/logs/*
6-
!app/cache/.gitkeep
7-
!app/logs/.gitkeep
8-
/app/phpunit.xml
92
/build/
3+
/phpunit.xml
4+
/var/bootstrap.php.cache
5+
/var/cache/*
6+
!var/cache/.gitkeep
7+
/var/logs/*
8+
!var/logs/.gitkeep
109
/vendor/
11-
/composer.phar
10+
/web/bundles/

app/AppKernel.php

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,21 @@ public function registerBundles()
2929
return $bundles;
3030
}
3131

32+
public function getRootDir()
33+
{
34+
return __DIR__;
35+
}
36+
37+
public function getCacheDir()
38+
{
39+
return dirname(__DIR__).'/var/cache/'.$this->environment;
40+
}
41+
42+
public function getLogDir()
43+
{
44+
return dirname(__DIR__).'/var/logs';
45+
}
46+
3247
public function registerContainerConfiguration(LoaderInterface $loader)
3348
{
3449
$loader->load($this->getRootDir().'/config/config_'.$this->getEnvironment().'.yml');

app/config/config.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@ framework:
3030
handler_id: ~
3131
fragments: ~
3232
http_method_override: true
33+
assets: ~
3334

3435
# Twig Configuration
3536
twig:

app/phpunit.xml.dist

Lines changed: 0 additions & 37 deletions
This file was deleted.

app/console renamed to bin/console

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ set_time_limit(0);
1515
* @var Composer\Autoload\ClassLoader $loader
1616
*/
1717
$loader = require __DIR__.'/../app/autoload.php';
18-
require_once __DIR__.'/AppKernel.php';
18+
require_once __DIR__.'/../app/AppKernel.php';
1919

2020
$input = new ArgvInput();
2121
$env = $input->getParameterOption(array('--env', '-e'), getenv('SYMFONY_ENV') ?: 'dev');

app/check.php renamed to bin/symfony_requirements

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
1+
#!/usr/bin/env php
12
<?php
23

3-
require_once dirname(__FILE__).'/SymfonyRequirements.php';
4+
require_once dirname(__FILE__).'/../var/SymfonyRequirements.php';
45

56
$lineSize = 70;
67
$symfonyRequirements = new SymfonyRequirements();

composer.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,8 @@
4141
},
4242
"extra": {
4343
"symfony-app-dir": "app",
44+
"symfony-bin-dir": "bin",
45+
"symfony-var-dir": "var",
4446
"symfony-web-dir": "web",
4547
"symfony-assets-install": "relative",
4648
"incenteev-parameters": {

composer.lock

Lines changed: 29 additions & 28 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

phpunit.xml.dist

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
3+
<!-- http://phpunit.de/manual/4.1/en/appendixes.configuration.html -->
4+
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
5+
xsi:noNamespaceSchemaLocation="http://schema.phpunit.de/4.1/phpunit.xsd"
6+
backupGlobals="false"
7+
colors="true"
8+
bootstrap="app/autoload.php"
9+
>
10+
<testsuites>
11+
<testsuite name="Project Test Suite">
12+
<directory>src/*/*Bundle/Tests</directory>
13+
<directory>src/*/Bundle/*Bundle/Tests</directory>
14+
<directory>src/*Bundle/Tests</directory>
15+
</testsuite>
16+
</testsuites>
17+
18+
<php>
19+
<server name="KERNEL_DIR" value="app/" />
20+
</php>
21+
22+
<filter>
23+
<whitelist>
24+
<directory>src</directory>
25+
<exclude>
26+
<directory>src/*Bundle/Resources</directory>
27+
<directory>src/*Bundle/Tests</directory>
28+
<directory>src/*/*Bundle/Resources</directory>
29+
<directory>src/*/*Bundle/Tests</directory>
30+
<directory>src/*/Bundle/*Bundle/Resources</directory>
31+
<directory>src/*/Bundle/*Bundle/Tests</directory>
32+
</exclude>
33+
</whitelist>
34+
</filter>
35+
</phpunit>
File renamed without changes.
File renamed without changes.
File renamed without changes.

web/app.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
* @var Composer\Autoload\ClassLoader
77
*/
88
$loader = require __DIR__.'/../app/autoload.php';
9-
include_once __DIR__.'/../app/bootstrap.php.cache';
9+
include_once __DIR__.'/../var/bootstrap.php.cache';
1010

1111
// Enable APC for autoloading to improve performance.
1212
// You should change the ApcClassLoader first argument to a unique prefix

0 commit comments

Comments
 (0)