roygoldman / composer-reinstall
composer 的重新安装命令。
1.0.1
2019-05-07 13:05 UTC
Requires
- composer-plugin-api: ^1.1
This package is auto-updated.
Last update: 2024-09-08 00:58:03 UTC
README
本软件包为 composer 提供了一个基本的重新安装命令。
关于
当使用 Composer 包管理器 时,您可能会在修改后或因为包的安装已损坏的情况下需要重新安装某个包。Composer 本身不提供 此命令,因此没有处理此过程的方法。本软件包提供了 composer 的重新安装命令。
工作原理
重新安装命令利用 composer 的安装机制,以确保正确安装包。为了强制 composer 重新安装包,您需要从系统中删除该包,然后运行 composer install
下载任何缺失的依赖项。使用新命令,包将从文件系统中删除,然后使用安装程序重新下载包。
安装
可以将此软件包添加到本地或全局 composer 安装中。要将软件包添加到您的项目中,请运行以下命令。
composer require roygoldman/composer-reinstall
用法
安装软件包后,您应该运行以下命令来重新安装指定的包或一系列包。
composer reinstall vendor/package [vendor/package2 ...]
选项
以下选项可用于 reinstall
命令。这些选项会影响 composer 处理包安装的方式。
--apcu-autoloader Use APCu to cache found/not-found classes.
-a, --classmap-authoritative Autoload classes from the classmap only. Implicitly enables `--optimize-autoloader`.
--dry-run Outputs the operations but will not execute anything (implicitly enables --verbose).
--no-autoloader Skips autoloader generation.
--no-dev Disables installation of require-dev packages.
--no-progress Do not output download progress.
--no-scripts Skips the execution of all scripts defined in composer.json file.
--no-suggest Do not show package suggestions.
--prefer-source Forces installation from package sources when possible, including VCS information.
--prefer-dist Forces installation from package dist even for dev versions.
-o, --optimize-autoloader Optimize autoloader during autoloader dump.
-h, --help Display this help message
-q, --quiet Do not output any message
-V, --version Display this application version
--ansi Force ANSI output
--no-ansi Disable ANSI output
-n, --no-interaction Do not ask any interactive question
--profile Display timing and memory usage information
--no-plugins Whether to disable plugins.
-d, --working-dir=WORKING-DIR If specified, use the given directory as working directory.
-v|vv|vvv, --verbose Increase the verbosity of messages: 1 for normal output, 2 for more verbose output and 3 for debug