-
Notifications
You must be signed in to change notification settings - Fork 11.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[9.x] Introducing a fresh new look for Artisan #43065
Conversation
Much cleaner. I like how it looks, and I like how you're separating feedback into Info and Error. |
Beautiful! Very impressive work, can't wait to see this land. |
First of all, I really like the new interface! Great job on this one. The only thing I'm not sure about is the choice component. The "Provider" and "Tag" labels are not clearly distinguishable, maybe because they don't have a highlight anymore. The same goes for some other commands with the choice output: What do you think? |
@denniseilander Done. |
In the
|
4130333
to
4a2d074
Compare
@Saifallak Maybe there should be a modified progress bar 🤔 |
@Saifallak @shaedrich Not sure where you got that idea. But, when a job starts goes into "processing" you see the time and the job name. The "DONE" on the right only appears when is actually done. |
I got that idea from screenshots,. |
This removed the id of a job when processing 😞 a105ae5#diff-68b410043fae33c9cecda76c3cf7c54a9073dd08eca46d44cb8d4424fae8dfd8L210 |
|
@nunomaduro was this tested on windows? This is MS terminal with WSL |
Hi All, I opened an issue a few minutes ago: I am trying to hunt down why my migrations don't work like they have since I upgraded to 9.21.0. I am wondering if at a glance what I am seeing might ring a bell. When I go back to 9.20.0 it works great, when I upgrade to 9.21.0 it's broken. Maybe the syntax or something changed, but that would seem odd. Anyhow, just trying to hunt it down. |
Wouldn't it be nice to have a config option for the character count (width)? Just in case that the default seems odd in some device/environment or the distance is too far from left to right, like for many data in the new Logic could be: Make width = config value (chars), but if any line of output needs more space: extend to kind of Or optionally (config value?) make a line break an stretch over two lines. That would also work with smaller width values. Otherwise I totally love the new design! :-) |
Fantastic work as always @nunomaduro 👏🏻 |
Looks great @nunomaduro but I think something might be wrong with the terminal / window width detection, or something? Running the latest Laravel 9.26. |
Hi, community. 👋🏻
For the past two weeks, I've been working on this pull request that introduces a fresh new look for Artisan. Before looking at the technical details, let's see some before/after comparisons:
Technical details:
A common change you will see in this pull request is all the previous command calls to
$this->info
,$this->warn
, etc, have been replaced by$this->components->info
, etc. This was made intentionally, to ensure only framework internal commands are affected by this new output.Now, besides the regular
$this->info
,$this->warn
, etc methods, we also introduce - in this pull request - new components that are used across the pull request. This list of components is:Alert
,BulletList
,Choice
,Component
,Confirm
,Error
,Factory
,Info
,Line
,Task
,TwoColumnDetail
,Warn
.As an example, the
$this->task
is used on the "queue:work" command to display the queue job description, the result of the queue job, and its duration.Now, keep in mind, that the
$this->components
property is marked as internal. Meaning that this pull request was not meant to introduce a public API for those components, but instead, simply to improve the output of Artisan itself.Also, these new components share something in common: they mutate the given information. By "mutate", I mean: we ensure punctuation, relative paths instead of absolute paths, and more. This is necessary to ensure things always look pretty.
This pull request effects more than 100 commands. Yet, it does not affect the following commands:
completion
,help
,List
,serve
,tinker
, and commands of Laravel packages such as Horizon or Telescope. In addition, it does not affect errors command from Symfony, such as invalid arguments, etc. All of this, can be done later, so we deliver this pull request first.Finally, would be very appreciated if the community could test this pull request in their L9 projects, as we plan to ship these changes in a minor release. To test this pull request locally, please follow this instructions: