Hi!
I have been working hard on yii-dev-tool lately. Here is a list of improvements that have been made.
1. Now you do not need to specify “yiisoft” in the package name. Just write the name of the repository.
For example, earlier command install
for package db-mysql was called like this:
./yii-dev install yiisoft/db-mysql
Now the command can be called like this:
./yii-dev install db-mysql
2. Now you can specify several packages for each command:
For example, earlier command update
for packages db-mysql, di and docs was called like this:
./yii-dev update yiisoft/db-mysql
./yii-dev update yiisoft/di
./yii-dev update yiisoft/docs
Now the command can be called like this:
./yii-dev update db-mysql,di,docs
3. The configuration structure has changed.
Now you can:
- install yiisoft package from the original repository using the HTTPS protocol
- install yiisoft package from a custom repository that is not on the GitHub
- do not install package at all
Examples of custom configurations:
[
// Default: Install yiisoft 'di' package from GitHub using SSH:
'di' => true, // use git@github.com:yiisoft/di.git
// Install yiisoft 'yii-console' package from GitHub using HTTPS:
'yii-console' => 'https', // use https://github.com/yiisoft/yii-console.git
// Install own fork of 'injector' package from GitHub using SSH:
'injector' => 'samdark/injector', // use git@github.com:samdark/injector.git
// Install 'db-mysql' package using the specified repository address:
'db-mysql' => 'https://samdark@bitbucket.org/yii/db-mysql.git', // use https://samdark@bitbucket.org/yii/db-mysql.git
// Do not install 'rbac' package at all:
'rbac' => false,
]
This allows you to flexibly manage your package structure and replace any package with your own for development.
4. The lint command is now available.
This command checks the code for compliance with the PSR-12 standard. For example, you can check packages rbac, access, docs and db as follows:
./yii-dev lint rbac,access,docs,db
5. Remote upstream
is now automatically configured for personal repositories.
For example, you forked repository yiisoft/injector and configured it as follows:
[
'injector' => 'samdark/injector',
]
Next, run the command:
./yii-dev install injector
During installation, git remote upstream will be automatically configured for the repository. To do this, an internal call of the following command will be made:
git remote add upstream https://github.com/yiisoft/injector.git
Previously, you had to do this manually: https://help.github.com/en/github/collaborating-with-issues-and-pull-requests/configuring-a-remote-for-a-fork
But now yii-dev-tool will automatically configure upstream for your forks and will use them when calling command ./yii-dev pull
.
6. Now error messages are aggregated and displayed at the end of each command.
For example, after calling command ./yii-dev install
at the end, you can see all the errors that occurred. You do not need to scroll and look for messages in the console output.
7. Many internal technical changes and improvements have been made.
Now the development of yii-dev-tool is based on components with object-oriented code inside. If anyone wants to help, welcome: https://github.com/yiisoft/yii-dev-tool/tree/master/src
If you regularly use yii-dev-tool, then any of your comments and suggestions will be very useful. Please create issues for any problems: https://github.com/yiisoft/yii-dev-tool/issues/new
Thanks
See also:
- A detailed example of how to contribute to Yii 3.0
- Yii-dev-tool enhancements