-
-
Notifications
You must be signed in to change notification settings - Fork 0
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
0 parents
commit 94a34ac
Showing
20 changed files
with
1,052 additions
and
0 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 |
---|---|---|
@@ -0,0 +1,12 @@ | ||
root = true | ||
|
||
[*] | ||
charset = utf-8 | ||
indent_style = space | ||
indent_size = 4 | ||
end_of_line = lf | ||
insert_final_newline = true | ||
trim_trailing_whitespace = true | ||
|
||
[*.md] | ||
trim_trailing_whitespace = false |
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 |
---|---|---|
@@ -0,0 +1,2 @@ | ||
# Auto detect text files and perform LF normalization | ||
* text=auto |
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 |
---|---|---|
@@ -0,0 +1,110 @@ | ||
# Created by https://www.toptal.com/developers/gitignore/api/macos,linux,symfony,windows,composer,visualstudiocode | ||
# Edit at https://www.toptal.com/developers/gitignore?templates=macos,linux,symfony,windows,composer,visualstudiocode | ||
|
||
### Composer ### | ||
composer.phar | ||
/vendor/ | ||
|
||
# Commit your application's lock file https://getcomposer.org/doc/01-basic-usage.md#commit-your-composer-lock-file-to-version-control | ||
# You may choose to ignore a library lock file http://getcomposer.org/doc/02-libraries.md#lock-file | ||
composer.lock | ||
|
||
### Linux ### | ||
*~ | ||
|
||
# temporary files which can be created if a process still has a handle open of a deleted file | ||
.fuse_hidden* | ||
|
||
# KDE directory preferences | ||
.directory | ||
|
||
# Linux trash folder which might appear on any partition or disk | ||
.Trash-* | ||
|
||
# .nfs files are created when an open file is removed but is still being accessed | ||
.nfs* | ||
|
||
### macOS ### | ||
# General | ||
.DS_Store | ||
.AppleDouble | ||
.LSOverride | ||
|
||
# Icon must end with two \r | ||
Icon | ||
|
||
# Thumbnails | ||
._* | ||
|
||
# Files that might appear in the root of a volume | ||
.DocumentRevisions-V100 | ||
.fseventsd | ||
.Spotlight-V100 | ||
.TemporaryItems | ||
.Trashes | ||
.VolumeIcon.icns | ||
.com.apple.timemachine.donotpresent | ||
|
||
# Directories potentially created on remote AFP share | ||
.AppleDB | ||
.AppleDesktop | ||
Network Trash Folder | ||
Temporary Items | ||
.apdisk | ||
|
||
### Symfony ### | ||
/var/ | ||
|
||
# PHPUnit | ||
/phpunit.xml | ||
.phpunit.result.cache | ||
|
||
# Build data | ||
/build/ | ||
|
||
# Composer PHAR | ||
/composer.phar | ||
|
||
### VisualStudioCode ### | ||
.vscode/* | ||
!.vscode/tasks.json | ||
!.vscode/launch.json | ||
*.code-workspace | ||
|
||
### VisualStudioCode Patch ### | ||
# Ignore all local history of files | ||
.history | ||
.ionide | ||
|
||
### Windows ### | ||
# Windows thumbnail cache files | ||
Thumbs.db | ||
Thumbs.db:encryptable | ||
ehthumbs.db | ||
ehthumbs_vista.db | ||
|
||
# Dump file | ||
*.stackdump | ||
|
||
# Folder config file | ||
[Dd]esktop.ini | ||
|
||
# Recycle Bin used on file shares | ||
$RECYCLE.BIN/ | ||
|
||
# Windows Installer files | ||
*.cab | ||
*.msi | ||
*.msix | ||
*.msm | ||
*.msp | ||
|
||
# Windows shortcuts | ||
*.lnk | ||
|
||
# dist files/folder | ||
*.dist | ||
# Not ignore | ||
!phpunit.xml.dist | ||
|
||
# End of https://www.toptal.com/developers/gitignore/api/macos,linux,symfony,windows,composer,visualstudiocode |
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 |
---|---|---|
@@ -0,0 +1,110 @@ | ||
<?php | ||
/* | ||
* This document has been generated with | ||
* https://mlocati.github.io/php-cs-fixer-configurator/#version:3.0.0|configurator | ||
* you can change this configuration by importing this file. | ||
*/ | ||
$config = new PhpCsFixer\Config(); | ||
|
||
return $config | ||
->setRiskyAllowed(true) | ||
->setRules([ | ||
'@DoctrineAnnotation' => true, | ||
'@PHP70Migration' => true, | ||
'@PHP71Migration' => true, | ||
'@PSR2' => true, | ||
'@Symfony' => true, | ||
'@PHP73Migration' => true, | ||
// Each line of multi-line DocComments must have an asterisk [PSR-5] and must be aligned with the first one. | ||
'align_multiline_comment' => true, | ||
// Each element of an array must be indented exactly once. | ||
'array_indentation' => true, | ||
// PHP arrays should be declared using the configured syntax. | ||
'array_syntax' => ['syntax' => 'short'], | ||
// Binary operators should be surrounded by space as configured. | ||
'binary_operator_spaces' => ['default' => 'align_single_space_minimal'], | ||
// An empty line feed must precede any configured statement. | ||
'blank_line_before_statement' => true, | ||
// The body of each structure MUST be enclosed by braces. Braces should be properly placed. Body of braces should be properly indented. | ||
'braces' => ['position_after_anonymous_constructs' => 'next', 'position_after_control_structures' => 'next', 'position_after_functions_and_oop_constructs' => 'next'], | ||
// Using `isset($var) &&` multiple times should be done in one call. | ||
'combine_consecutive_issets' => true, | ||
// Calling `unset` on multiple items should be done in one call. | ||
'combine_consecutive_unsets' => true, | ||
// Replace multiple nested calls of `dirname` by only one call with second `$level` parameter. Requires PHP >= 7.0. | ||
'combine_nested_dirname' => true, | ||
// Remove extra spaces in a nullable typehint. | ||
'compact_nullable_typehint' => true, | ||
// Equal sign in declare statement should be surrounded by spaces or not following configuration. | ||
'declare_equal_normalize' => ['space' => 'single'], | ||
// Replaces `dirname(__FILE__)` expression with equivalent `__DIR__` constant. | ||
'dir_constant' => true, | ||
// Replace deprecated `ereg` regular expression functions with `preg`. | ||
'ereg_to_preg' => true, | ||
// Add curly braces to indirect variables to make them clear to understand. Requires PHP >= 7.0. | ||
'explicit_indirect_variable' => true, | ||
// Converts implicit variables into explicit ones in double-quoted strings or heredoc syntax. | ||
'explicit_string_variable' => true, | ||
// Replace core functions calls returning constants with the constants. | ||
'function_to_constant' => true, | ||
// Convert `heredoc` to `nowdoc` where possible. | ||
'heredoc_to_nowdoc' => true, | ||
// Ensure there is no code on the same line as the PHP open tag. | ||
'linebreak_after_opening_tag' => true, | ||
// Method chaining MUST be properly indented. Method chaining with different levels of indentation is not supported. | ||
'method_chaining_indentation' => true, | ||
// Replaces `intval`, `floatval`, `doubleval`, `strval` and `boolval` function calls with according type casting operator. | ||
'modernize_types_casting' => true, | ||
// DocBlocks must start with two asterisks, multiline comments must start with a single asterisk, after the opening slash. Both must end with a single asterisk before the closing slash. | ||
'multiline_comment_opening_closing' => true, | ||
// Forbid multi-line whitespace before the closing semicolon or move the semicolon to the new line for chained calls. | ||
'multiline_whitespace_before_semicolons' => ['strategy' => 'new_line_for_chained_calls'], | ||
// Add leading `\` before function invocation to speed up resolving. | ||
'native_function_invocation' => true, | ||
// Master functions shall be used instead of aliases. | ||
'no_alias_functions' => true, | ||
// Replace control structure alternative syntax to use braces. | ||
'no_alternative_syntax' => true, | ||
// Properties MUST not be explicitly initialized with `null` except when they have a type declaration (PHP 7.4). | ||
'no_null_property_initialization' => true, | ||
// Variables must be set `null` instead of using `(unset)` casting. | ||
'no_unset_cast' => true, | ||
// There should not be an empty `return` statement at the end of a function. | ||
'no_useless_return' => true, | ||
// Logical NOT operators (`!`) should have leading and trailing whitespaces. | ||
'not_operator_with_space' => true, | ||
// Adds or removes `?` before type declarations for parameters with a default `null` value. | ||
'nullable_type_declaration_for_default_null_value' => true, | ||
// Orders the elements of classes/interfaces/traits. | ||
'ordered_class_elements' => true, | ||
// Ordering `use` statements. | ||
'ordered_imports' => true, | ||
// All PHPUnit test classes should be marked as internal. | ||
'php_unit_internal_class' => true, | ||
// Enforce camel (or snake) case for PHPUnit test methods, following configuration. | ||
'php_unit_method_casing' => true, | ||
// Adds a default `@coversNothing` annotation to PHPUnit test classes that have no `@covers*` annotation. | ||
'php_unit_test_class_requires_covers' => true, | ||
// PHPDoc should contain `@param` for all params. | ||
'phpdoc_add_missing_param_annotation' => true, | ||
// `@return void` and `@return null` annotations should be omitted from PHPDoc. | ||
'phpdoc_no_empty_return' => true, | ||
// Annotations in PHPDoc should be ordered so that `@param` annotations come first, then `@throws` annotations, then `@return` annotations. | ||
'phpdoc_order' => true, | ||
// `@var` and `@type` annotations must have type and name in the correct order. | ||
'phpdoc_var_annotation_correct_order' => true, | ||
// Local, dynamic and directly referenced variables should not be assigned and directly returned by a function or method. | ||
'return_assignment' => true, | ||
// Converts explicit variables in double-quoted strings and heredoc syntax from simple to complex format (`${` to `{$`). | ||
'simple_to_complex_string_variable' => true, | ||
// Simplify `if` control structures that return the boolean result of their condition. | ||
'simplified_if_return' => true, | ||
// A return statement wishing to return `void` should not return `null`. | ||
'simplified_null_return' => true, | ||
]) | ||
->setFinder( | ||
PhpCsFixer\Finder::create() | ||
->exclude('vendor') | ||
->in(__DIR__) | ||
) | ||
; |
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 |
---|---|---|
@@ -0,0 +1,29 @@ | ||
BSD 3-Clause License | ||
|
||
Copyright (c) 2021, IDMarinas | ||
All rights reserved. | ||
|
||
Redistribution and use in source and binary forms, with or without | ||
modification, are permitted provided that the following conditions are met: | ||
|
||
1. Redistributions of source code must retain the above copyright notice, this | ||
list of conditions and the following disclaimer. | ||
|
||
2. Redistributions in binary form must reproduce the above copyright notice, | ||
this list of conditions and the following disclaimer in the documentation | ||
and/or other materials provided with the distribution. | ||
|
||
3. Neither the name of the copyright holder nor the names of its | ||
contributors may be used to endorse or promote products derived from | ||
this software without specific prior written permission. | ||
|
||
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" | ||
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE | ||
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE | ||
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE | ||
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL | ||
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR | ||
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER | ||
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, | ||
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE | ||
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
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 |
---|---|---|
@@ -0,0 +1,28 @@ | ||
# LoTGD Bunde Garden Party | ||
|
||
Party in the Garden of all cities. | ||
|
||
# Install | ||
```bash | ||
composer require lotgd-core/bundle-garden-party | ||
``` | ||
|
||
# Default configuration | ||
```yaml | ||
# Note: party duration is 24 hours always. | ||
lotgd_garden_party: | ||
# When does the part start. Valid format for DateTime object | ||
start: null # Required, Example: '2015-01-20 use this format YYYY-MM-DD' | ||
# How often is the party repeated? By default repeated every year | ||
repeat: P1Y # Example: 'http://php.net/manual/en/dateinterval.construct.php for examples of format' | ||
cake: | ||
# Cost per level for cake | ||
cost: 20 | ||
# How many slices of cake can a player buy in one day? | ||
max: 3 | ||
drink: | ||
# Cost per level for drink | ||
cost: 20 | ||
# How many party drinks can a player buy in one day? | ||
max: 3 | ||
``` |
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 |
---|---|---|
@@ -0,0 +1,71 @@ | ||
{ | ||
"name": "lotgd-core/bundle-garden-party", | ||
"description": "Party in the Garden of all cities.", | ||
"version": "0.1.0", | ||
"type": "lotgd-bundle", | ||
"license": "BSD-3-Clause", | ||
"authors": [ | ||
{ | ||
"name": "Iván Diaz Marinas (IDMarinas)", | ||
"email": "35842929+idmarinas@users.noreply.github.com", | ||
"homepage": "https://github.com/lotgd-core/bundle-garden-party", | ||
"role": "Developer" | ||
}, | ||
{ | ||
"name": "Eric Stevens", | ||
"role": "Original Idea" | ||
} | ||
], | ||
"config": { | ||
"optimize-autoloader": true, | ||
"preferred-install": { | ||
"*": "dist" | ||
}, | ||
"process-timeout": 5000, | ||
"sort-packages": true | ||
}, | ||
"support": { | ||
"issues": "https://github.com/lotgd-core/bundle-garden-party/issues" | ||
}, | ||
"minimum-stability": "dev", | ||
"prefer-stable": true, | ||
"require": { | ||
"php": ">=7.3", | ||
"idmarinas/lotgd-contracts": "^0.2.0", | ||
"symfony/dependency-injection": "^4.4|^5.0", | ||
"symfony/framework-bundle": "^4.4|^5.0", | ||
"symfony/http-kernel": "^4.4|^5.0", | ||
"symfony/yaml": "^4.4|^5.0" | ||
}, | ||
"require-dev": { | ||
"idmarinas/lotgd": "^6.0", | ||
"matthiasnoback/symfony-config-test": "^4.2", | ||
"matthiasnoback/symfony-dependency-injection-test": "^4.2", | ||
"nyholm/symfony-bundle-test": "^1.7", | ||
"phpunit/phpunit": "^8.5", | ||
"symfony/phpunit-bridge": "^5.3", | ||
"symfony/test-pack": "^1.0" | ||
}, | ||
"conflict": { | ||
"idmarinas/lotgd": "<6.0" | ||
}, | ||
"autoload": { | ||
"psr-4": { | ||
"Lotgd\\Bundle\\GardenParty\\": "src/" | ||
} | ||
}, | ||
"autoload-dev": { | ||
"psr-4": { | ||
"Lotgd\\Bundle\\GardenParty\\Tests\\": "tests/" | ||
} | ||
}, | ||
"scripts": { | ||
"test": "phpunit" | ||
}, | ||
"funding": [ | ||
{ | ||
"type": "paypal", | ||
"url": "https://www.paypal.me/idmarinas" | ||
} | ||
] | ||
} |
Oops, something went wrong.