-
Notifications
You must be signed in to change notification settings - Fork 12
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
Slim CLI? #1
Comments
It would be a good idea to integrate into a separate repo. CLIs require a kitchen sink of dependencies so isolating it to its own repo is better imo. |
@l0gicgate I agree with you, this should be a separate repository. We can create a new repository, for example Slim-console, and I will work in it, if we really need this feature. |
I'm definitely open to new features that improve the end user UX. Let's get some feedback in here and see what we should put in there |
@ABGEO07 @l0gicgate Would it make sense to put a CLI component as a part of https://github.com/slimphp/Slim-Skeleton ?
|
Is this supposed to be a cli tool for Slim powered web applications like artisan is for Laravel? Or is it a slim cli framework for creating cli applications? |
@l0gicgate Can i start implement thie CLI Component ? |
First one :) |
@mgamal92 Waiting for feedback. After that I will start working on it. |
I would make the life of the cron-jobs much easier :) +1 vote from me |
Thanks for the clarification |
What's the status of this? Has a new repo been created? I'd like to contribute to this effort. |
I need to create a new repo. We also need to figure out how the CLI will be built. What are we going to use to create a console? I have experience with symfony/console. Any other suggestions? Also, what is going to be the initial functionality?
I need more input |
I would suggest the initial functionality be create a project (prompting the user for what interfaces they want to use for error control, DI, etc.), Routes with a hello-world skeleton action. Other features to be added later may be validation and sanitation middleware. My suggestion is to use Robo with Climate. I've used this successfully in the Willow Framework |
I would like to see something like in the yii2 framework's cli interface(especially their |
This means:
https://www.yiiframework.com/extension/yiisoft/yii2-gii/doc/guide/2.1/en/basic-usage But where are the models, controllers, forms, modules and extensions in Slim? |
Excuse me for being short wording my comment, of course I meant just the idea of generating code from stubs, instead of controllers, modules, etc for example Action classes etc. |
This is an overkill, slim is small allowing everyone to define their own structure and have their own way of implementation and not a kitchen sink. |
We use Slim as the basis for all our applications, adding default modules, structured base classes, a CLI module, a bundle approach and several other useful additions to it. Slim is fantastic here because it's completely un-opinionated about everything not request and response, and that is how it should be IMHO: Otherwise you could just use Yii/Symfony/Laravel. Still, I am in favor of adding a command line interface to Slim, for two reasons:
To make this as easy as possible, I'd suggest using Symfony Console. That's the basis of composer, Laravel's artisan, the Symfony console and countless other tools. It's a simple, battle-tested, well-documented way to create console applications in PHP. I'd volunteer to participate here, too :) |
@l0gicgate
For future plans:
👍 for Symfony Console. I am a user of Slim and would like to contribute too. |
I would love to contribute :) I use Slim all the time :)
for boilerplate, i love how @akrabat is putting it all together. |
@l0gicgate I agree with @flangofas road map as well as 5 others have given a thumbs up. Is anything else needed before a repo can be created for this? |
I will be creating the repo here shortly. Should we call it Also the initial feature set will be:
We will be moving this discussion in the new repository when it's created and we can make a roadmap there. |
What would the namespace names be like?
Personally, I don't like all caps in namespaces, but that's maybe only me. |
vs.
My vote goes to Slim\Console |
@l0gicgate nice to hear that from you🙂 I can immediately start working on the application when we get the repository. P.S. I vote for the name |
I think |
Anyone have thoughts on the idea of these two types of console commands?
Preset Command
Make Commands
Examples of possible preset commands
Examples of possible make:commands
=== How cool would it be if Slim never lost it's unbiased view point, but made it extremely easy to setup preset and make commands so once a development team inevitably decides on an implementation that even if the slim preset/make console package that it was easy enough to make that they would create it themselves. Slim console itself is a core package, but then each preset/make group was its own package that acts as a sort of plug-in or provided service into the slim console package. We never lose the agnostic view point of core, but still provide the ability to easily expedite and enforce the decided upon implementation. If extremely easy, I think this would go leaps and bounds to pushing slim open source contribution to the next level. I don't know, maybe I'm just a little too excited at this point ~ what's everyone else's thoughts? |
I agree, I think we should make something that is framework agnostic but that can easily be integrated with some popular libraries easily. For now let's try and focus on one command at a time and have some thorough discussions around them. I will open separate issues for each. Let's continue the conversations in those threads |
Hello,
I think it would be nice to create a new Slim component - CLI Console (like Symfony Console), to start the PHP Dev server, Debug router and Container, Generating Routes and Actions etc.
If you agree with me, I can immediately start working on it.
The text was updated successfully, but these errors were encountered: