Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
23 changed files
with
168 additions
and
321 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,26 +1,20 @@ | ||
# EditorConfig is awesome: http://EditorConfig.org | ||
|
||
# Top-most EditorConfig file | ||
root = true | ||
|
||
# Unix-style newlines with a newline ending every file | ||
[*] | ||
charset = utf-8 | ||
end_of_line = lf | ||
insert_final_newline = true | ||
|
||
# JS / PHP | ||
[*.{js,php,phpt}] | ||
charset = utf-8 | ||
trim_trailing_whitespace = true | ||
indent_style = tab | ||
indent_size = 4 | ||
indent_size = tab | ||
tab_width = 4 | ||
|
||
# NEON | ||
[*.neon] | ||
charset = utf-8 | ||
indent_style = tab | ||
[*.md] | ||
indent_style = space | ||
indent_size = 4 | ||
|
||
# Composer, NPM, Travis, BitbucketPipelines | ||
[{composer.json,package.json,.travis.yml,bitbucket-pipelines.yml}] | ||
[{composer.json,package.json,.travis.yml}] | ||
indent_style = space | ||
indent_size = 2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,6 +6,8 @@ | |
/composer.lock | ||
|
||
# Tests | ||
/temp/ | ||
/tests/*.log | ||
/tests/tmp | ||
/tests/coverage.html | ||
/coverage.xml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
includes: | ||
- temp/phpstan/vendor/phpstan/phpstan-strict-rules/rules.neon | ||
- temp/phpstan/vendor/phpstan/phpstan-nette/extension.neon | ||
- temp/phpstan/vendor/phpstan/phpstan-nette/rules.neon | ||
|
||
parameters: | ||
- temp/phpstan/vendor/phpstan/phpstan-deprecation-rules/rules.neon |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,29 +1,22 @@ | ||
<?php | ||
<?php declare(strict_types = 1); | ||
|
||
namespace Contributte\Utils\DI; | ||
|
||
use Contributte\Utils\DatetimeFactory; | ||
use Contributte\Utils\IDateTimeFactory; | ||
use Nette\DI\CompilerExtension; | ||
|
||
/** | ||
* @author Milan Felix Sulc <sulcmil@gmail.com> | ||
*/ | ||
class DateTimeFactoryExtension extends CompilerExtension | ||
{ | ||
|
||
/** | ||
* Register services | ||
* | ||
* @return void | ||
*/ | ||
public function loadConfiguration() | ||
public function loadConfiguration(): void | ||
{ | ||
$builder = $this->getContainerBuilder(); | ||
|
||
$builder->addDefinition($this->prefix('factory')) | ||
->setClass(IDateTimeFactory::class) | ||
->setFactory(DatetimeFactory::class); | ||
->setImplement(IDateTimeFactory::class); | ||
} | ||
|
||
} |
Oops, something went wrong.