diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 00000000..a8f5e15a --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,40 @@ +name: "Plugin release" + +on: + push: + tags: + - '*' + +jobs: + create-release: + name: "Create release" + runs-on: "ubuntu-latest" + steps: + - name: "Extract tag name" + run: | + echo "tag_name=${GITHUB_REF#refs/tags/}" >> $GITHUB_ENV + - name: "Checkout" + uses: "actions/checkout@v2" + - name: "Build package" + id: "build-package" + uses: "glpi-project/tools/github-actions/build-package@0.1.15" + with: + plugin-version: ${{ env.tag_name }} + - name: "Create release" + id: "create-release" + uses: "actions/create-release@v1" + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + tag_name: ${{ env.tag_name }} + release_name: ${{ env.tag_name }} + draft: true + - name: "Attach package to release" + uses: "actions/upload-release-asset@v1" + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + upload_url: ${{ steps.create-release.outputs.upload_url }} + asset_path: ${{ steps.build-package.outputs.package-path }} + asset_name: ${{ steps.build-package.outputs.package-basename }} + asset_content_type: " application/x-bzip2" diff --git a/composer.lock b/composer.lock index a111dd2f..8062514b 100644 --- a/composer.lock +++ b/composer.lock @@ -9,46 +9,33 @@ "packages-dev": [ { "name": "consolidation/annotated-command", - "version": "4.2.3", + "version": "4.2.4", "source": { "type": "git", "url": "https://github.com/consolidation/annotated-command.git", - "reference": "4b596872f24c39d9c04d7b3adb6bc51baa1f2fd5" + "reference": "ec297e05cb86557671c2d6cbb1bebba6c7ae2c60" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/consolidation/annotated-command/zipball/4b596872f24c39d9c04d7b3adb6bc51baa1f2fd5", - "reference": "4b596872f24c39d9c04d7b3adb6bc51baa1f2fd5", + "url": "https://api.github.com/repos/consolidation/annotated-command/zipball/ec297e05cb86557671c2d6cbb1bebba6c7ae2c60", + "reference": "ec297e05cb86557671c2d6cbb1bebba6c7ae2c60", "shasum": "" }, "require": { "consolidation/output-formatters": "^4.1.1", "php": ">=7.1.3", "psr/log": "^1|^2", - "symfony/console": "^4.4.8|^5", + "symfony/console": "^4.4.8|~5.1.0", "symfony/event-dispatcher": "^4.4.8|^5", "symfony/finder": "^4.4.8|^5" }, "require-dev": { - "g1a/composer-test-scenarios": "^3", - "php-coveralls/php-coveralls": "^2.2", - "phpunit/phpunit": "^6", - "squizlabs/php_codesniffer": "^3" + "phpunit/phpunit": ">=7.5.20", + "squizlabs/php_codesniffer": "^3", + "yoast/phpunit-polyfills": "^0.2.0" }, "type": "library", "extra": { - "scenarios": { - "symfony4": { - "require": { - "symfony/console": "^4.0" - }, - "config": { - "platform": { - "php": "7.1.3" - } - } - } - }, "branch-alias": { "dev-main": "4.x-dev" } @@ -69,55 +56,48 @@ } ], "description": "Initialize Symfony Console commands from annotated command class methods.", - "time": "2020-10-03T14:28:42+00:00" + "support": { + "issues": "https://github.com/consolidation/annotated-command/issues", + "source": "https://github.com/consolidation/annotated-command/tree/4.2.4" + }, + "time": "2020-12-10T16:56:39+00:00" }, { "name": "consolidation/config", - "version": "2.0.0", + "version": "2.0.1", "source": { "type": "git", "url": "https://github.com/consolidation/config.git", - "reference": "9842670aad3406dbc8df3069fd680a9f8cd6edd7" + "reference": "9a2c2a7b2aea1b3525984a4378743a8b74c14e1c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/consolidation/config/zipball/9842670aad3406dbc8df3069fd680a9f8cd6edd7", - "reference": "9842670aad3406dbc8df3069fd680a9f8cd6edd7", + "url": "https://api.github.com/repos/consolidation/config/zipball/9a2c2a7b2aea1b3525984a4378743a8b74c14e1c", + "reference": "9a2c2a7b2aea1b3525984a4378743a8b74c14e1c", "shasum": "" }, "require": { "dflydev/dot-access-data": "^1.1.0", "grasmash/expander": "^1", - "php": ">=7.1.3" + "php": ">=7.1.3", + "psr/log": "^1.1", + "symfony/event-dispatcher": "^4||^5" }, "require-dev": { - "g1a/composer-test-scenarios": "^3", - "php-coveralls/php-coveralls": "^2.2", - "phpunit/phpunit": "^6", + "phpunit/phpunit": ">=7.5.20", "squizlabs/php_codesniffer": "^3", - "symfony/console": "^4|^5", - "symfony/event-dispatcher": "^4|^5", - "symfony/yaml": "^4|^5" + "symfony/console": "^4||^5", + "symfony/yaml": "^4||^5", + "yoast/phpunit-polyfills": "^0.2.0" }, "suggest": { + "symfony/event-dispatcher": "Required to inject configuration into Command options", "symfony/yaml": "Required to use Consolidation\\Config\\Loader\\YamlConfigLoader" }, "type": "library", "extra": { - "scenarios": { - "symfony4": { - "require-dev": { - "symfony/console": "^4" - }, - "config": { - "platform": { - "php": "7.1.3" - } - } - } - }, "branch-alias": { - "dev-master": "2.x-dev" + "dev-main": "2.x-dev" } }, "autoload": { @@ -136,20 +116,24 @@ } ], "description": "Provide configuration services for a commandline tool.", - "time": "2020-05-27T17:11:23+00:00" + "support": { + "issues": "https://github.com/consolidation/config/issues", + "source": "https://github.com/consolidation/config/tree/2.0.1" + }, + "time": "2020-12-06T00:03:30+00:00" }, { "name": "consolidation/log", - "version": "2.0.1", + "version": "2.0.2", "source": { "type": "git", "url": "https://github.com/consolidation/log.git", - "reference": "ba0bf6af1fbd09ed4dc18fc2f27b12ceff487cbf" + "reference": "82a2aaaa621a7b976e50a745a8d249d5085ee2b1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/consolidation/log/zipball/ba0bf6af1fbd09ed4dc18fc2f27b12ceff487cbf", - "reference": "ba0bf6af1fbd09ed4dc18fc2f27b12ceff487cbf", + "url": "https://api.github.com/repos/consolidation/log/zipball/82a2aaaa621a7b976e50a745a8d249d5085ee2b1", + "reference": "82a2aaaa621a7b976e50a745a8d249d5085ee2b1", "shasum": "" }, "require": { @@ -158,27 +142,14 @@ "symfony/console": "^4|^5" }, "require-dev": { - "g1a/composer-test-scenarios": "^3", - "php-coveralls/php-coveralls": "^2.2", - "phpunit/phpunit": "^6", - "squizlabs/php_codesniffer": "^3" + "phpunit/phpunit": ">=7.5.20", + "squizlabs/php_codesniffer": "^3", + "yoast/phpunit-polyfills": "^0.2.0" }, "type": "library", "extra": { - "scenarios": { - "symfony4": { - "require-dev": { - "symfony/console": "^4" - }, - "config": { - "platform": { - "php": "7.1.3" - } - } - } - }, "branch-alias": { - "dev-master": "2.x-dev" + "dev-main": "2.x-dev" } }, "autoload": { @@ -197,20 +168,24 @@ } ], "description": "Improved Psr-3 / Psr\\Log logger based on Symfony Console components.", - "time": "2020-05-27T17:06:13+00:00" + "support": { + "issues": "https://github.com/consolidation/log/issues", + "source": "https://github.com/consolidation/log/tree/2.0.2" + }, + "time": "2020-12-10T16:26:23+00:00" }, { "name": "consolidation/output-formatters", - "version": "4.1.1", + "version": "4.1.2", "source": { "type": "git", "url": "https://github.com/consolidation/output-formatters.git", - "reference": "9deeddd6a916d0a756b216a8b40ce1016e17c0b9" + "reference": "5821e6ae076bf690058a4de6c94dce97398a69c9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/consolidation/output-formatters/zipball/9deeddd6a916d0a756b216a8b40ce1016e17c0b9", - "reference": "9deeddd6a916d0a756b216a8b40ce1016e17c0b9", + "url": "https://api.github.com/repos/consolidation/output-formatters/zipball/5821e6ae076bf690058a4de6c94dce97398a69c9", + "reference": "5821e6ae076bf690058a4de6c94dce97398a69c9", "shasum": "" }, "require": { @@ -220,32 +195,20 @@ "symfony/finder": "^4|^5" }, "require-dev": { - "g1a/composer-test-scenarios": "^3", - "php-coveralls/php-coveralls": "^2.2", - "phpunit/phpunit": "^6", + "php-coveralls/php-coveralls": "^2.4.2", + "phpunit/phpunit": ">=7", "squizlabs/php_codesniffer": "^3", "symfony/var-dumper": "^4", - "symfony/yaml": "^4" + "symfony/yaml": "^4", + "yoast/phpunit-polyfills": "^0.2.0" }, "suggest": { "symfony/var-dumper": "For using the var_dump formatter" }, "type": "library", "extra": { - "scenarios": { - "symfony4": { - "require": { - "symfony/console": "^4.0" - }, - "config": { - "platform": { - "php": "7.1.3" - } - } - } - }, "branch-alias": { - "dev-master": "4.x-dev" + "dev-main": "4.x-dev" } }, "autoload": { @@ -264,20 +227,24 @@ } ], "description": "Format text by applying transformations provided by plug-in formatters.", - "time": "2020-05-27T20:51:17+00:00" + "support": { + "issues": "https://github.com/consolidation/output-formatters/issues", + "source": "https://github.com/consolidation/output-formatters/tree/4.1.2" + }, + "time": "2020-12-12T19:04:59+00:00" }, { "name": "consolidation/robo", - "version": "2.2.1", + "version": "2.2.2", "source": { "type": "git", "url": "https://github.com/consolidation/Robo.git", - "reference": "1a7c652371615fd72ff05380ffe6ce263eb31eb3" + "reference": "b365df174d9cfb0f5814e4f3275a1c558b17bc4c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/consolidation/Robo/zipball/1a7c652371615fd72ff05380ffe6ce263eb31eb3", - "reference": "1a7c652371615fd72ff05380ffe6ce263eb31eb3", + "url": "https://api.github.com/repos/consolidation/Robo/zipball/b365df174d9cfb0f5814e4f3275a1c558b17bc4c", + "reference": "b365df174d9cfb0f5814e4f3275a1c558b17bc4c", "shasum": "" }, "require": { @@ -292,7 +259,8 @@ "symfony/event-dispatcher": "^4.4.11|^5", "symfony/filesystem": "^4.4.11|^5", "symfony/finder": "^4.4.11|^5", - "symfony/process": "^4.4.11|^5" + "symfony/process": "^4.4.11|^5", + "symfony/yaml": "^4.0 || ^5.0" }, "conflict": { "codegyre/robo": "*" @@ -360,7 +328,11 @@ } ], "description": "Modern task runner", - "time": "2020-09-08T16:23:18+00:00" + "support": { + "issues": "https://github.com/consolidation/Robo/issues", + "source": "https://github.com/consolidation/Robo/tree/2.2.2" + }, + "time": "2020-12-18T22:09:18+00:00" }, { "name": "consolidation/self-update", @@ -410,6 +382,10 @@ } ], "description": "Provides a self:update command for Symfony Console applications.", + "support": { + "issues": "https://github.com/consolidation/self-update/issues", + "source": "https://github.com/consolidation/self-update/tree/1.2.0" + }, "time": "2020-04-13T02:49:20+00:00" }, { @@ -441,9 +417,83 @@ ], "description": "Promoting the interoperability of container objects (DIC, SL, etc.)", "homepage": "https://github.com/container-interop/container-interop", + "support": { + "issues": "https://github.com/container-interop/container-interop/issues", + "source": "https://github.com/container-interop/container-interop/tree/master" + }, "abandoned": "psr/container", "time": "2017-02-14T19:40:03+00:00" }, + { + "name": "dealerdirect/phpcodesniffer-composer-installer", + "version": "v0.7.1", + "source": { + "type": "git", + "url": "https://github.com/Dealerdirect/phpcodesniffer-composer-installer.git", + "reference": "fe390591e0241955f22eb9ba327d137e501c771c" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/Dealerdirect/phpcodesniffer-composer-installer/zipball/fe390591e0241955f22eb9ba327d137e501c771c", + "reference": "fe390591e0241955f22eb9ba327d137e501c771c", + "shasum": "" + }, + "require": { + "composer-plugin-api": "^1.0 || ^2.0", + "php": ">=5.3", + "squizlabs/php_codesniffer": "^2.0 || ^3.0 || ^4.0" + }, + "require-dev": { + "composer/composer": "*", + "phpcompatibility/php-compatibility": "^9.0", + "sensiolabs/security-checker": "^4.1.0" + }, + "type": "composer-plugin", + "extra": { + "class": "Dealerdirect\\Composer\\Plugin\\Installers\\PHPCodeSniffer\\Plugin" + }, + "autoload": { + "psr-4": { + "Dealerdirect\\Composer\\Plugin\\Installers\\PHPCodeSniffer\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Franck Nijhof", + "email": "franck.nijhof@dealerdirect.com", + "homepage": "http://www.frenck.nl", + "role": "Developer / IT Manager" + } + ], + "description": "PHP_CodeSniffer Standards Composer Installer Plugin", + "homepage": "http://www.dealerdirect.com", + "keywords": [ + "PHPCodeSniffer", + "PHP_CodeSniffer", + "code quality", + "codesniffer", + "composer", + "installer", + "phpcs", + "plugin", + "qa", + "quality", + "standard", + "standards", + "style guide", + "stylecheck", + "tests" + ], + "support": { + "issues": "https://github.com/dealerdirect/phpcodesniffer-composer-installer/issues", + "source": "https://github.com/dealerdirect/phpcodesniffer-composer-installer" + }, + "time": "2020-12-07T18:04:37+00:00" + }, { "name": "dflydev/dot-access-data", "version": "v1.1.0", @@ -501,24 +551,29 @@ "dot", "notation" ], + "support": { + "issues": "https://github.com/dflydev/dflydev-dot-access-data/issues", + "source": "https://github.com/dflydev/dflydev-dot-access-data/tree/master" + }, "time": "2017-01-20T21:14:22+00:00" }, { "name": "glpi-project/coding-standard", - "version": "0.7.2", + "version": "0.8", "source": { "type": "git", "url": "https://github.com/glpi-project/coding-standard.git", - "reference": "dbba6566e1ce7f7d0778794cd6e93bc07080c8c7" + "reference": "a34ec2abf52e720ef700f59a91a4dde963b9f33e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/glpi-project/coding-standard/zipball/dbba6566e1ce7f7d0778794cd6e93bc07080c8c7", - "reference": "dbba6566e1ce7f7d0778794cd6e93bc07080c8c7", + "url": "https://api.github.com/repos/glpi-project/coding-standard/zipball/a34ec2abf52e720ef700f59a91a4dde963b9f33e", + "reference": "a34ec2abf52e720ef700f59a91a4dde963b9f33e", "shasum": "" }, "require": { - "squizlabs/php_codesniffer": "^3.5" + "slevomat/coding-standard": "^6.3", + "squizlabs/php_codesniffer": "^3.5.5" }, "type": "library", "notification-url": "https://packagist.org/downloads/", @@ -538,32 +593,37 @@ "glpi", "phpcs" ], - "time": "2019-10-31T10:30:33+00:00" + "support": { + "issues": "https://github.com/glpi-project/coding-standard/issues", + "source": "https://github.com/glpi-project/coding-standard" + }, + "time": "2020-06-03T08:54:27+00:00" }, { "name": "glpi-project/tools", - "version": "0.1.14", + "version": "0.1.15", "source": { "type": "git", "url": "https://github.com/glpi-project/tools.git", - "reference": "fd2d9d5a8a465640efe8f20334a6ee302cafe05e" + "reference": "b51d5e70321e32ac5e5ba0b5ccc851b41e1a078b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/glpi-project/tools/zipball/fd2d9d5a8a465640efe8f20334a6ee302cafe05e", - "reference": "fd2d9d5a8a465640efe8f20334a6ee302cafe05e", + "url": "https://api.github.com/repos/glpi-project/tools/zipball/b51d5e70321e32ac5e5ba0b5ccc851b41e1a078b", + "reference": "b51d5e70321e32ac5e5ba0b5ccc851b41e1a078b", "shasum": "" }, "require": { "consolidation/robo": "^1.3 || ^2.0", - "glpi-project/coding-standard": "^0.7", + "glpi-project/coding-standard": "^0.8", "natxet/cssmin": "^3.0", - "patchwork/jsqueeze": "^1.0" + "patchwork/jsqueeze": "^1.0", + "symfony/console": "^4.4 || ^5.0" }, "bin": [ - "tools/plugin-release", + "bin/licence-headers-check", "tools/extract_template.sh", - "tools/modify_headers.pl" + "tools/plugin-release" ], "type": "library", "autoload": { @@ -588,7 +648,11 @@ "plugins", "tools" ], - "time": "2020-10-26T07:33:44+00:00" + "support": { + "issues": "https://github.com/glpi-project/tools/issues", + "source": "https://github.com/glpi-project/tools" + }, + "time": "2021-01-18T06:47:45+00:00" }, { "name": "grasmash/expander", @@ -635,6 +699,10 @@ } ], "description": "Expands internal property references in PHP arrays file.", + "support": { + "issues": "https://github.com/grasmash/expander/issues", + "source": "https://github.com/grasmash/expander/tree/master" + }, "time": "2017-12-21T22:14:55+00:00" }, { @@ -700,10 +768,14 @@ "provider", "service" ], + "support": { + "issues": "https://github.com/thephpleague/container/issues", + "source": "https://github.com/thephpleague/container/tree/2.x" + }, "time": "2017-05-10T09:20:27+00:00" }, { - "name": "natxet/CssMin", + "name": "natxet/cssmin", "version": "v3.0.6", "source": { "type": "git", @@ -747,6 +819,10 @@ "css", "minify" ], + "support": { + "issues": "https://github.com/natxet/CssMin/issues", + "source": "https://github.com/natxet/CssMin/tree/master" + }, "time": "2018-01-09T11:15:01+00:00" }, { @@ -789,9 +865,66 @@ "javascript", "minification" ], + "support": { + "issues": "https://github.com/tchwork/jsqueeze/issues", + "source": "https://github.com/tchwork/jsqueeze/tree/v1.0.7" + }, "abandoned": true, "time": "2015-03-25T10:11:08+00:00" }, + { + "name": "phpstan/phpdoc-parser", + "version": "0.4.9", + "source": { + "type": "git", + "url": "https://github.com/phpstan/phpdoc-parser.git", + "reference": "98a088b17966bdf6ee25c8a4b634df313d8aa531" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/phpstan/phpdoc-parser/zipball/98a088b17966bdf6ee25c8a4b634df313d8aa531", + "reference": "98a088b17966bdf6ee25c8a4b634df313d8aa531", + "shasum": "" + }, + "require": { + "php": "^7.1 || ^8.0" + }, + "require-dev": { + "consistence/coding-standard": "^3.5", + "ergebnis/composer-normalize": "^2.0.2", + "jakub-onderka/php-parallel-lint": "^0.9.2", + "phing/phing": "^2.16.0", + "phpstan/extension-installer": "^1.0", + "phpstan/phpstan": "^0.12.26", + "phpstan/phpstan-strict-rules": "^0.12", + "phpunit/phpunit": "^6.3", + "slevomat/coding-standard": "^4.7.2", + "symfony/process": "^4.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "0.4-dev" + } + }, + "autoload": { + "psr-4": { + "PHPStan\\PhpDocParser\\": [ + "src/" + ] + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "description": "PHPDoc parser with support for nullable, intersection and generic types", + "support": { + "issues": "https://github.com/phpstan/phpdoc-parser/issues", + "source": "https://github.com/phpstan/phpdoc-parser/tree/master" + }, + "time": "2020-08-03T20:32:43+00:00" + }, { "name": "psr/container", "version": "1.0.0", @@ -839,6 +972,10 @@ "container-interop", "psr" ], + "support": { + "issues": "https://github.com/php-fig/container/issues", + "source": "https://github.com/php-fig/container/tree/master" + }, "time": "2017-02-14T16:28:37+00:00" }, { @@ -886,8 +1023,72 @@ "psr", "psr-3" ], + "support": { + "source": "https://github.com/php-fig/log/tree/1.1.3" + }, "time": "2020-03-23T09:12:05+00:00" }, + { + "name": "slevomat/coding-standard", + "version": "6.4.1", + "source": { + "type": "git", + "url": "https://github.com/slevomat/coding-standard.git", + "reference": "696dcca217d0c9da2c40d02731526c1e25b65346" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/slevomat/coding-standard/zipball/696dcca217d0c9da2c40d02731526c1e25b65346", + "reference": "696dcca217d0c9da2c40d02731526c1e25b65346", + "shasum": "" + }, + "require": { + "dealerdirect/phpcodesniffer-composer-installer": "^0.6.2 || ^0.7", + "php": "^7.1 || ^8.0", + "phpstan/phpdoc-parser": "0.4.5 - 0.4.9", + "squizlabs/php_codesniffer": "^3.5.6" + }, + "require-dev": { + "phing/phing": "2.16.3", + "php-parallel-lint/php-parallel-lint": "1.2.0", + "phpstan/phpstan": "0.12.48", + "phpstan/phpstan-deprecation-rules": "0.12.5", + "phpstan/phpstan-phpunit": "0.12.16", + "phpstan/phpstan-strict-rules": "0.12.5", + "phpunit/phpunit": "7.5.20|8.5.5|9.4.0" + }, + "type": "phpcodesniffer-standard", + "extra": { + "branch-alias": { + "dev-master": "6.x-dev" + } + }, + "autoload": { + "psr-4": { + "SlevomatCodingStandard\\": "SlevomatCodingStandard" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "description": "Slevomat Coding Standard for PHP_CodeSniffer complements Consistence Coding Standard by providing sniffs with additional checks.", + "support": { + "issues": "https://github.com/slevomat/coding-standard/issues", + "source": "https://github.com/slevomat/coding-standard/tree/6.4.1" + }, + "funding": [ + { + "url": "https://github.com/kukulich", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/slevomat/coding-standard", + "type": "tidelift" + } + ], + "time": "2020-10-05T12:39:37+00:00" + }, { "name": "squizlabs/php_codesniffer", "version": "3.5.8", @@ -937,20 +1138,25 @@ "phpcs", "standards" ], + "support": { + "issues": "https://github.com/squizlabs/PHP_CodeSniffer/issues", + "source": "https://github.com/squizlabs/PHP_CodeSniffer", + "wiki": "https://github.com/squizlabs/PHP_CodeSniffer/wiki" + }, "time": "2020-10-23T02:01:07+00:00" }, { "name": "symfony/console", - "version": "v4.4.15", + "version": "v4.4.18", "source": { "type": "git", "url": "https://github.com/symfony/console.git", - "reference": "90933b39c7b312fc3ceaa1ddeac7eb48cb953124" + "reference": "12e071278e396cc3e1c149857337e9e192deca0b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/console/zipball/90933b39c7b312fc3ceaa1ddeac7eb48cb953124", - "reference": "90933b39c7b312fc3ceaa1ddeac7eb48cb953124", + "url": "https://api.github.com/repos/symfony/console/zipball/12e071278e396cc3e1c149857337e9e192deca0b", + "reference": "12e071278e396cc3e1c149857337e9e192deca0b", "shasum": "" }, "require": { @@ -985,11 +1191,6 @@ "symfony/process": "" }, "type": "library", - "extra": { - "branch-alias": { - "dev-master": "4.4-dev" - } - }, "autoload": { "psr-4": { "Symfony\\Component\\Console\\": "" @@ -1014,6 +1215,9 @@ ], "description": "Symfony Console Component", "homepage": "https://symfony.com", + "support": { + "source": "https://github.com/symfony/console/tree/v4.4.18" + }, "funding": [ { "url": "https://symfony.com/sponsor", @@ -1028,20 +1232,20 @@ "type": "tidelift" } ], - "time": "2020-09-15T07:58:55+00:00" + "time": "2020-12-18T07:41:31+00:00" }, { "name": "symfony/event-dispatcher", - "version": "v4.4.15", + "version": "v4.4.18", "source": { "type": "git", "url": "https://github.com/symfony/event-dispatcher.git", - "reference": "e17bb5e0663dc725f7cdcafc932132735b4725cd" + "reference": "5d4c874b0eb1c32d40328a09dbc37307a5a910b0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/e17bb5e0663dc725f7cdcafc932132735b4725cd", - "reference": "e17bb5e0663dc725f7cdcafc932132735b4725cd", + "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/5d4c874b0eb1c32d40328a09dbc37307a5a910b0", + "reference": "5d4c874b0eb1c32d40328a09dbc37307a5a910b0", "shasum": "" }, "require": { @@ -1070,11 +1274,6 @@ "symfony/http-kernel": "" }, "type": "library", - "extra": { - "branch-alias": { - "dev-master": "4.4-dev" - } - }, "autoload": { "psr-4": { "Symfony\\Component\\EventDispatcher\\": "" @@ -1099,6 +1298,9 @@ ], "description": "Symfony EventDispatcher Component", "homepage": "https://symfony.com", + "support": { + "source": "https://github.com/symfony/event-dispatcher/tree/v4.4.18" + }, "funding": [ { "url": "https://symfony.com/sponsor", @@ -1113,7 +1315,7 @@ "type": "tidelift" } ], - "time": "2020-09-18T14:07:46+00:00" + "time": "2020-12-18T07:41:31+00:00" }, { "name": "symfony/event-dispatcher-contracts", @@ -1175,6 +1377,9 @@ "interoperability", "standards" ], + "support": { + "source": "https://github.com/symfony/event-dispatcher-contracts/tree/v1.1.9" + }, "funding": [ { "url": "https://symfony.com/sponsor", @@ -1193,16 +1398,16 @@ }, { "name": "symfony/filesystem", - "version": "v4.4.15", + "version": "v4.4.18", "source": { "type": "git", "url": "https://github.com/symfony/filesystem.git", - "reference": "ebc51494739d3b081ea543ed7c462fa73a4f74db" + "reference": "d99fbef7e0f69bf162ae6131b31132fa3cc4bcbe" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/filesystem/zipball/ebc51494739d3b081ea543ed7c462fa73a4f74db", - "reference": "ebc51494739d3b081ea543ed7c462fa73a4f74db", + "url": "https://api.github.com/repos/symfony/filesystem/zipball/d99fbef7e0f69bf162ae6131b31132fa3cc4bcbe", + "reference": "d99fbef7e0f69bf162ae6131b31132fa3cc4bcbe", "shasum": "" }, "require": { @@ -1210,11 +1415,6 @@ "symfony/polyfill-ctype": "~1.8" }, "type": "library", - "extra": { - "branch-alias": { - "dev-master": "4.4-dev" - } - }, "autoload": { "psr-4": { "Symfony\\Component\\Filesystem\\": "" @@ -1239,6 +1439,9 @@ ], "description": "Symfony Filesystem Component", "homepage": "https://symfony.com", + "support": { + "source": "https://github.com/symfony/filesystem/tree/v4.4.18" + }, "funding": [ { "url": "https://symfony.com/sponsor", @@ -1253,31 +1456,26 @@ "type": "tidelift" } ], - "time": "2020-09-27T13:54:16+00:00" + "time": "2020-11-30T13:04:35+00:00" }, { "name": "symfony/finder", - "version": "v4.4.15", + "version": "v4.4.18", "source": { "type": "git", "url": "https://github.com/symfony/finder.git", - "reference": "60d08560f9aa72997c44077c40d47aa28a963230" + "reference": "ebd0965f2dc2d4e0f11487c16fbb041e50b5c09b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/finder/zipball/60d08560f9aa72997c44077c40d47aa28a963230", - "reference": "60d08560f9aa72997c44077c40d47aa28a963230", + "url": "https://api.github.com/repos/symfony/finder/zipball/ebd0965f2dc2d4e0f11487c16fbb041e50b5c09b", + "reference": "ebd0965f2dc2d4e0f11487c16fbb041e50b5c09b", "shasum": "" }, "require": { "php": ">=7.1.3" }, "type": "library", - "extra": { - "branch-alias": { - "dev-master": "4.4-dev" - } - }, "autoload": { "psr-4": { "Symfony\\Component\\Finder\\": "" @@ -1302,6 +1500,9 @@ ], "description": "Symfony Finder Component", "homepage": "https://symfony.com", + "support": { + "source": "https://github.com/symfony/finder/tree/v4.4.18" + }, "funding": [ { "url": "https://symfony.com/sponsor", @@ -1316,20 +1517,20 @@ "type": "tidelift" } ], - "time": "2020-10-02T07:34:48+00:00" + "time": "2020-12-08T16:59:59+00:00" }, { "name": "symfony/polyfill-ctype", - "version": "v1.20.0", + "version": "v1.22.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-ctype.git", - "reference": "f4ba089a5b6366e453971d3aad5fe8e897b37f41" + "reference": "c6c942b1ac76c82448322025e084cadc56048b4e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/f4ba089a5b6366e453971d3aad5fe8e897b37f41", - "reference": "f4ba089a5b6366e453971d3aad5fe8e897b37f41", + "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/c6c942b1ac76c82448322025e084cadc56048b4e", + "reference": "c6c942b1ac76c82448322025e084cadc56048b4e", "shasum": "" }, "require": { @@ -1341,7 +1542,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "1.20-dev" + "dev-main": "1.22-dev" }, "thanks": { "name": "symfony/polyfill", @@ -1378,6 +1579,9 @@ "polyfill", "portable" ], + "support": { + "source": "https://github.com/symfony/polyfill-ctype/tree/v1.22.0" + }, "funding": [ { "url": "https://symfony.com/sponsor", @@ -1392,20 +1596,20 @@ "type": "tidelift" } ], - "time": "2020-10-23T14:02:19+00:00" + "time": "2021-01-07T16:49:33+00:00" }, { "name": "symfony/polyfill-mbstring", - "version": "v1.20.0", + "version": "v1.22.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-mbstring.git", - "reference": "39d483bdf39be819deabf04ec872eb0b2410b531" + "reference": "f377a3dd1fde44d37b9831d68dc8dea3ffd28e13" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/39d483bdf39be819deabf04ec872eb0b2410b531", - "reference": "39d483bdf39be819deabf04ec872eb0b2410b531", + "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/f377a3dd1fde44d37b9831d68dc8dea3ffd28e13", + "reference": "f377a3dd1fde44d37b9831d68dc8dea3ffd28e13", "shasum": "" }, "require": { @@ -1417,7 +1621,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "1.20-dev" + "dev-main": "1.22-dev" }, "thanks": { "name": "symfony/polyfill", @@ -1455,6 +1659,9 @@ "portable", "shim" ], + "support": { + "source": "https://github.com/symfony/polyfill-mbstring/tree/v1.22.0" + }, "funding": [ { "url": "https://symfony.com/sponsor", @@ -1469,20 +1676,20 @@ "type": "tidelift" } ], - "time": "2020-10-23T14:02:19+00:00" + "time": "2021-01-07T16:49:33+00:00" }, { "name": "symfony/polyfill-php73", - "version": "v1.20.0", + "version": "v1.22.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-php73.git", - "reference": "8ff431c517be11c78c48a39a66d37431e26a6bed" + "reference": "a678b42e92f86eca04b7fa4c0f6f19d097fb69e2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-php73/zipball/8ff431c517be11c78c48a39a66d37431e26a6bed", - "reference": "8ff431c517be11c78c48a39a66d37431e26a6bed", + "url": "https://api.github.com/repos/symfony/polyfill-php73/zipball/a678b42e92f86eca04b7fa4c0f6f19d097fb69e2", + "reference": "a678b42e92f86eca04b7fa4c0f6f19d097fb69e2", "shasum": "" }, "require": { @@ -1491,7 +1698,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "1.20-dev" + "dev-main": "1.22-dev" }, "thanks": { "name": "symfony/polyfill", @@ -1531,6 +1738,9 @@ "portable", "shim" ], + "support": { + "source": "https://github.com/symfony/polyfill-php73/tree/v1.22.0" + }, "funding": [ { "url": "https://symfony.com/sponsor", @@ -1545,20 +1755,20 @@ "type": "tidelift" } ], - "time": "2020-10-23T14:02:19+00:00" + "time": "2021-01-07T16:49:33+00:00" }, { "name": "symfony/polyfill-php80", - "version": "v1.20.0", + "version": "v1.22.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-php80.git", - "reference": "e70aa8b064c5b72d3df2abd5ab1e90464ad009de" + "reference": "dc3063ba22c2a1fd2f45ed856374d79114998f91" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/e70aa8b064c5b72d3df2abd5ab1e90464ad009de", - "reference": "e70aa8b064c5b72d3df2abd5ab1e90464ad009de", + "url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/dc3063ba22c2a1fd2f45ed856374d79114998f91", + "reference": "dc3063ba22c2a1fd2f45ed856374d79114998f91", "shasum": "" }, "require": { @@ -1567,7 +1777,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "1.20-dev" + "dev-main": "1.22-dev" }, "thanks": { "name": "symfony/polyfill", @@ -1611,6 +1821,9 @@ "portable", "shim" ], + "support": { + "source": "https://github.com/symfony/polyfill-php80/tree/v1.22.0" + }, "funding": [ { "url": "https://symfony.com/sponsor", @@ -1625,31 +1838,26 @@ "type": "tidelift" } ], - "time": "2020-10-23T14:02:19+00:00" + "time": "2021-01-07T16:49:33+00:00" }, { "name": "symfony/process", - "version": "v4.4.15", + "version": "v4.4.18", "source": { "type": "git", "url": "https://github.com/symfony/process.git", - "reference": "9b887acc522935f77555ae8813495958c7771ba7" + "reference": "075316ff72233ce3d04a9743414292e834f2cb4a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/process/zipball/9b887acc522935f77555ae8813495958c7771ba7", - "reference": "9b887acc522935f77555ae8813495958c7771ba7", + "url": "https://api.github.com/repos/symfony/process/zipball/075316ff72233ce3d04a9743414292e834f2cb4a", + "reference": "075316ff72233ce3d04a9743414292e834f2cb4a", "shasum": "" }, "require": { "php": ">=7.1.3" }, "type": "library", - "extra": { - "branch-alias": { - "dev-master": "4.4-dev" - } - }, "autoload": { "psr-4": { "Symfony\\Component\\Process\\": "" @@ -1674,6 +1882,9 @@ ], "description": "Symfony Process Component", "homepage": "https://symfony.com", + "support": { + "source": "https://github.com/symfony/process/tree/v4.4.18" + }, "funding": [ { "url": "https://symfony.com/sponsor", @@ -1688,7 +1899,7 @@ "type": "tidelift" } ], - "time": "2020-09-02T16:08:58+00:00" + "time": "2020-12-08T16:59:59+00:00" }, { "name": "symfony/service-contracts", @@ -1750,6 +1961,9 @@ "interoperability", "standards" ], + "support": { + "source": "https://github.com/symfony/service-contracts/tree/v1.1.9" + }, "funding": [ { "url": "https://symfony.com/sponsor", @@ -1765,6 +1979,77 @@ } ], "time": "2020-07-06T13:19:58+00:00" + }, + { + "name": "symfony/yaml", + "version": "v4.4.18", + "source": { + "type": "git", + "url": "https://github.com/symfony/yaml.git", + "reference": "bbce94f14d73732340740366fcbe63363663a403" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/yaml/zipball/bbce94f14d73732340740366fcbe63363663a403", + "reference": "bbce94f14d73732340740366fcbe63363663a403", + "shasum": "" + }, + "require": { + "php": ">=7.1.3", + "symfony/polyfill-ctype": "~1.8" + }, + "conflict": { + "symfony/console": "<3.4" + }, + "require-dev": { + "symfony/console": "^3.4|^4.0|^5.0" + }, + "suggest": { + "symfony/console": "For validating YAML files using the lint command" + }, + "type": "library", + "autoload": { + "psr-4": { + "Symfony\\Component\\Yaml\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony Yaml Component", + "homepage": "https://symfony.com", + "support": { + "source": "https://github.com/symfony/yaml/tree/v4.4.18" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2020-12-08T16:59:59+00:00" } ], "aliases": [], @@ -1779,5 +2064,5 @@ "platform-overrides": { "php": "7.2.0" }, - "plugin-api-version": "1.1.0" + "plugin-api-version": "2.0.0" } diff --git a/datainjection.xml b/datainjection.xml index 4d48211c..3cbe6dfc 100644 --- a/datainjection.xml +++ b/datainjection.xml @@ -28,6 +28,11 @@ Xavier Caillaud + + 2.9.0 + ~9.5.0 + https://github.com/pluginsGLPI/datainjection/releases/download/2.9.0/glpi-datainjection-2.9.0.tar.bz2 + 2.8.1 ~9.5.0 diff --git a/inc/applianceinjection.class.php b/inc/applianceinjection.class.php new file mode 100644 index 00000000..80a7e4c3 --- /dev/null +++ b/inc/applianceinjection.class.php @@ -0,0 +1,82 @@ +. + -------------------------------------------------------------------------- + @package datainjection + @author the datainjection plugin team + @copyright Copyright (c) 2010-2017 Datainjection plugin team + @license GPLv2+ + http://www.gnu.org/licenses/gpl.txt + @link https://github.com/pluginsGLPI/datainjection + @link http://www.glpi-project.org/ + @since 2009 + ---------------------------------------------------------------------- */ + +if (!defined('GLPI_ROOT')) { + die("Sorry. You can't access directly to this file"); +} + +class PluginDatainjectionApplianceInjection extends Appliance + implements PluginDatainjectionInjectionInterface +{ + + static function getTable($classname = null) { + $parenttype = get_parent_class(); + return $parenttype::getTable(); + } + + function isPrimaryType() { + return true; + } + + function connectedTo() { + return []; + } + + /** + * @see plugins/datainjection/inc/PluginDatainjectionInjectionInterface::getOptions() + **/ + function getOptions($primary_type = '') { + + $tab = Search::getOptions(get_parent_class($this)); + + //Remove some options because some fields cannot be imported + $blacklist = PluginDatainjectionCommonInjectionLib::getBlacklistedOptions(get_parent_class($this)); + $notimportable = [5, 9, 31]; + + $options['ignore_fields'] = array_merge($blacklist, $notimportable); + $options['displaytype'] = [ + "multiline_text" => [4], + "dropdown" => [10, 11, 32], + "user" => [6, 24], + "bool" => [7, 61] + ]; + + return PluginDatainjectionCommonInjectionLib::addToSearchOptions($tab, $options, $this); + } + + /** + * @see plugins/datainjection/inc/PluginDatainjectionInjectionInterface::addOrUpdateObject() + **/ + function addOrUpdateObject($values = [], $options = []) { + $lib = new PluginDatainjectionCommonInjectionLib($this, $values, $options); + $lib->processAddOrUpdate(); + return $lib->getInjectionResults(); + } +} \ No newline at end of file diff --git a/setup.php b/setup.php index 99197a0e..ee1d9828 100644 --- a/setup.php +++ b/setup.php @@ -28,7 +28,7 @@ @since 2009 ---------------------------------------------------------------------- */ -define ('PLUGIN_DATAINJECTION_VERSION', '2.8.1'); +define ('PLUGIN_DATAINJECTION_VERSION', '2.9.0'); // Minimal GLPI version, inclusive define("PLUGIN_DATAINJECTION_MIN_GLPI", "9.5"); @@ -208,7 +208,8 @@ function getTypesToInject() { 'PluginDatainjectionDeviceHardDriveInjection' => 'datainjection', 'PluginDatainjectionDeviceMotherboardInjection' => 'datainjection', 'PluginDatainjectionDeviceDriveInjection' => 'datainjection', - 'PluginDatainjectionDeviceNetworkCardInjection' => 'datainjection' + 'PluginDatainjectionDeviceNetworkCardInjection' => 'datainjection', + 'PluginDatainjectionApplianceInjection' => 'datainjection' ]; //Add plugins Plugin::doHook('plugin_datainjection_populate');