shipfastlabs/link
最新稳定版本:v1.0.3
Composer 安装命令:
composer require shipfastlabs/link
包简介
Link local packages for development by modifying composer.json and composer.lock
README 文档
README
Link
Link local packages for development by modifying composer.json and composer.lock.
Requires PHP 8.2+ and Composer 2.6+
Installation
Install globally so it's available in all your projects:
composer global require shipfastlabs/link
Or install per-project:
composer require shipfastlabs/link --dev
Usage
Link a local package
composer link ../packages/my-package
This will:
- Add a
pathrepository entry to yourcomposer.json - Update the
requireconstraint to*so Composer resolves from the local path - Run
composer updateto updatecomposer.lockand symlink the package
Link multiple packages with wildcards
composer link ../packages/*
Only link packages that are already in your composer.lock:
composer link ../packages/* --only-installed
List linked packages
composer linked
Unlink a package
composer unlink ../packages/my-package
This restores the original version constraint in composer.json and runs composer update to install the released version from Packagist.
Unlink all packages
composer unlink-all
How it works
Unlike composer-link which works in-memory, this plugin modifies your composer.json and composer.lock files directly:
composer linkadds apathrepository tocomposer.jsonand runscomposer updatecomposer unlinkremoves the path repository, restores the original constraint, and runscomposer update- Original version constraints are tracked in
vendor/composer-link.jsonso they can be restored on unlink - Both
requireandrequire-devpackages are supported
Development
composer lint # Format code with Pint composer refactor # Run Rector refactors composer test:types # Static analysis with PHPStan composer test:unit # Unit tests with Pest composer test # Run the entire test suite
License
Link is open-sourced software licensed under the MIT license.
统计信息
- 总下载量: 5
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 1
- 点击次数: 6
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2026-02-12
