File tree Expand file tree Collapse file tree 5 files changed +23
-12
lines changed Expand file tree Collapse file tree 5 files changed +23
-12
lines changed Original file line number Diff line number Diff line change @@ -5,15 +5,20 @@ sudo: false
55php :
66 - 7.0
77 - 7.1
8+ - 7.2
89 - nightly
910
1011matrix :
1112 fast_finish : true
1213 include :
1314 - php : 7.0
1415 env : COMPOSER_FLAGS="--prefer-lowest" SYMFONY_DEPRECATIONS_HELPER=weak
16+ # Test LTS versions
1517 - php : 7.1
16- env : DEPENDENCIES=dev SYMFONY_DEPRECATIONS_HELPER=weak
18+ env : DEPENDENCIES="dunglas/symfony-lock:^3"
19+ # Test unstable versions
20+ - php : 7.2
21+ env : STABILITY="dev"
1722 allow_failures :
1823 - php : nightly
1924
2227 - $HOME/.composer/cache/files
2328
2429before_install :
25- - if [ "$DEPENDENCIES" = "dev" ]; then perl -pi -e 's/^}$/,"minimum-stability":"dev"}/' composer.json; fi;
30+ - if ! [ -z "$STABILITY" ]; then composer config minimum-stability ${STABILITY}; fi;
31+ - if ! [ -v "$DEPENDENCIES" ]; then composer require --no-update ${DEPENDENCIES}; fi;
2632
27- install : composer update $COMPOSER_FLAGS
33+ install : composer update $COMPOSER_FLAGS --prefer-dist --no-interaction
2834
2935script : phpunit -v
Original file line number Diff line number Diff line change 1111 ],
1212 "require" : {
1313 "php" : " ^7.0" ,
14- "symfony/asset" : " ^3.2" ,
15- "symfony/cache" : " ^3.2" ,
16- "symfony/config" : " ^3.2" ,
17- "symfony/dependency-injection" : " ^3.2" ,
18- "symfony/finder" : " ^3.2" ,
19- "symfony/framework-bundle" : " ^3.2" ,
20- "symfony/http-kernel" : " ^3.2"
14+ "symfony/asset" : " ^3.2 || ^4.0 " ,
15+ "symfony/cache" : " ^3.2 || ^4.0 " ,
16+ "symfony/config" : " ^3.2 || ^4.0 " ,
17+ "symfony/dependency-injection" : " ^3.2 || ^4.0 " ,
18+ "symfony/finder" : " ^3.2 || ^4.0 " ,
19+ "symfony/framework-bundle" : " ^3.2 || ^4.0 " ,
20+ "symfony/http-kernel" : " ^3.2 || ^4.0 "
2121 },
2222 "require-dev" : {
23- "symfony/phpunit-bridge" : " ^3.2 "
23+ "symfony/phpunit-bridge" : " ^4.0 "
2424 },
2525 "autoload" : {
2626 "psr-4" : {
Original file line number Diff line number Diff line change 55use Symfony \Component \Finder \Finder ;
66use Symfony \Component \Finder \SplFileInfo ;
77
8+ /**
9+ * @internal
10+ */
811class AssetFinder
912{
1013 private $ webRoot ;
Original file line number Diff line number Diff line change 44
55use Symfony \Component \Config \Definition \Builder \TreeBuilder ;
66use Symfony \Component \Config \Definition \ConfigurationInterface ;
7+ use Symfony \Flex \Recipe ;
78
89class Configuration implements ConfigurationInterface
910{
@@ -16,7 +17,7 @@ public function getConfigTreeBuilder()
1617 $ rootNode = $ treeBuilder ->root ('incenteev_hashed_asset ' );
1718
1819 $ rootNode ->children ()
19- ->scalarNode ('web_root ' )->defaultValue ('%kernel.root_dir%/../web ' )->end ()
20+ ->scalarNode ('web_root ' )->defaultValue (\class_exists (Recipe::class) ? ' %kernel.project_dir%/public ' : '%kernel.root_dir%/../web ' )->end ()
2021 ->scalarNode ('version_format ' )->defaultValue ('%%s?%%s ' )->end ()
2122 ;
2223
Original file line number Diff line number Diff line change @@ -10,6 +10,7 @@ public function __construct(string $webRoot)
1010 {
1111 $ this ->webRoot = $ webRoot ;
1212 }
13+
1314 public function computeHash (string $ path ): string
1415 {
1516 $ fullPath = $ this ->webRoot .'/ ' .ltrim ($ path , '/ ' );
You can’t perform that action at this time.
0 commit comments