Interactive Make Command for Laravel

Overview

Interactive Make for Laravel 5.4

Latest Stable Version Total Downloads Latest Unstable Version License

Getting Started

To get started you need to install the package with Composer:

composer require laracademy/interactive-make

Laravel >= 5.5

That's it! The package is auto-discovered on 5.5 and up!

Laravel <= 5.4

Add the package service provider to your providers array in config/app.php

'providers' => [
    // ...
    Laracademy\Commands\MakeServiceProvider::class,
],

To start using this package, run this command in your terminal and follow the onscreen prompts:

php artisan make

Preview

Disclaimer

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

Comments
  • Laravel 6

    Laravel 6

    Used this package for a long time. It hasn't worked with Laravel 6 and I miss it.

    Any plans to support Laravel 6?

    php artisan make

    migration Table Name (Example: users): test Are you creating a new table (yes/no) [no]: no Setting table option for table test

    In MakeCommand.php line 225:

    Trying to access array offset on value of type null

    opened by IndexZer0 4
  • make:model is not creating controller or migration

    make:model is not creating controller or migration

    ` What command are you running?: [auth ] Auth [controller ] Controller [command ] Command [event ] Event [job ] Job [listener ] Listener [mail ] Mail [middleware ] Middleware [migration ] Migration [model ] Model [notification] Notification [policy ] Policy [provider ] Provider [request ] Request [seeder ] Seeder [test ] Test

    model

    Model Name (Example: Posts):

    Order

    Do you want to make a migration for this model? (yes/no) [no]:

    yes

    Do you want to make a controller for this model? (yes/no) [no]:

    yes

    Is this controller a resourceful controller? (yes/no) [no]:

    no

    Model created successfully.`

    After this snippet of commands in terminal only model App\Order is created, no migration or controller were created. However, when I go with command "controller" both controller and model are created successfully and for the migration I need to user migration command. Why the make:model approach is not creating controller or migration?

    opened by kskrlin 4
  • Contribution list

    Contribution list

    like the package, and I want to contribute on it, here is a list of suggested contributions

    • [ ] support nested resource controller generation
    • [ ] support "event:generate" as a top level command, or as a suggestion question in the event or handler make commands.
    • [ ] add extra command than the official one, specially for tasks like "make:component" for generation vue component.
    • [ ] check if developer install common 3rd party generator like Laravel-5-Generators-Extended and support there features

    If any of these contribution fit with your plan, I will be happy to submit a PR to support any of them ;)

    opened by devmsh 4
  • The switch for unit tests does not work

    The switch for unit tests does not work

    When I try and make a test the script asks me whether it's a unit test or not. This is, I guess, to know whether to use the --unit flag in the make:test artisan command.

    However, this does not work. Whatever I answer to that question, the new test is always created in app/test/Feature. I'm using version 0.9

    bug 
    opened by troccoli 2
  • Updated to include 5.5's make:factory command

    Updated to include 5.5's make:factory command

    Added an option to create a model factory based on 5.5's new make:factory command.

    Since you've got a check for existing command or not, I guess this is safe to pull in already if you want to.

    Also, sorry, I've got an auto formatter for PSR styling, it changed some small stuff here and there in the file :/

    opened by jpmurray 1
  • Support for package auto-discovery

    Support for package auto-discovery

    Well, that was easy!

    This will make the package auto-load in Laravel 5.5 ans up, and it doesn't conflict with anything for earlier versions that will need to include the service provider.

    opened by jpmurray 1
  • Making a model with all options does not create migration/resourceful controller.

    Making a model with all options does not create migration/resourceful controller.

    $ ./artisan make
     What command are you running?:
     ...
     > model
     Model Name (Example: Posts):
     > Chairs
     Do you want to make a migration for this model? (yes/no) [no]:
     > yes
     Do you want to make a controller for this model? (yes/no) [no]:
     > yes
     Is this controller a resourceful controller? (yes/no) [no]:
     > yes
    Model created successfully.
    

    Running git status shows the following:

    app/Chairs.php
    

    Running the command manually:

    ./artisan make:model Chairs --migration --controller --resource
    Model created successfully.
    Created Migration: 2017_05_04_133413_create_chairs_table
    Controller created successfully.
    

    Now, running git status shows the following:

    app/Chairs.php
    app/Http/Controllers/ChairsController.php
    database/migrations/2017_05_04_133413_create_chairs_table.php
    

    I'm running Laravel 5.4.21.

    bug 
    opened by vaughany 1
  • make:controller does not generate resourceful controller

    make:controller does not generate resourceful controller

    Laravel 5.2 generates empty controller using 'interactive make'. However using 'php artisan make:controller TestController --resource' artisan generates resourceful controller.

    bug 
    opened by doobas 1
  • Alter table not using correct table name in Schema::table().

    Alter table not using correct table name in Schema::table().

    Hi, you recently made interactive-make work with laravel 6.

    Seems that the generated migration file is incorrect for an alter table scenario.

    I'm expecting the first parameter of Schema::table() to be 'table_name' - instead its the name of migration file ('alter_table_name_table_add_x_column').

    Screenshot 2020-03-04 at 15 27 56 Screenshot 2020-03-04 at 15 28 05

    P.S - if you do take a look at this... could you also see if this package works with laravel 7 which was release this past week? We haven't upgraded ourself yet but probably will soon.

    opened by IndexZer0 2
Releases(1.6)
Owner
Laracademy
Laracademy
A Laravel Artisan SQL Interactive Interface

sqli A Laravel 4 & 5 Artisan SQL Interactive Interface, plus a handful of Artisan commands to execute SQL queries. sqli It's like tinker for SQL, just

Antonio Carlos Ribeiro 61 Apr 18, 2022
A simple `make:view` command for Laravel applications.

A simple make:view command for Laravel applications. Quickly generate a new Blade view from the console using artisan make:view. Installation You can

Ryan Chandler 10 Oct 17, 2022
A make:pivot command to create a pivot table with Laravel

make:pivot for Laravel Installation Requires PHP 8.0.0+ You can install the package via composer: composer require felixdorn/laravel-make-pivot-table

Félix Dorn 13 Aug 23, 2022
This package provides you with a simplistic `php artisan make:user` command

Laracademy Generators Laracademy make:user Command - provides you with a simplistic artisan command to generate users from the console. Author(s): Lar

Laracademy 18 Jan 19, 2019
Make custom helper just with one command!

Laravel Custom Helper Make custom helper just with one command! Very light!!! Installation requires Laravel 8+ Via composer: $ composer require Ranjba

Ali Ranjbar 2 Aug 23, 2022
A light weight laravel package that facilitates dealing with arabic concepts using a set of classes and methods to make laravel speaks arabic

A light weight laravel package that facilitates dealing with arabic concepts using a set of classes and methods to make laravel speaks arabic! concepts like , Hijri Dates & Arabic strings and so on ..

Adnane Kadri 49 Jun 22, 2022
Postgis extensions for laravel. Aims to make it easy to work with geometries from laravel models.

Laravel Wrapper for PostgreSQL's Geo-Extension Postgis Features Work with geometry classes instead of arrays. $model->myPoint = new Point(1,2); //lat

Max 340 Jan 6, 2023
Make Laravel Pivot Tables using the new Laravel 9 closure migration format

This will allow you to create pivot table migration files using the new Laravel 9 closure migration format by simply passing two models.

Jose Jimenez 16 Aug 23, 2022
A Laravel package helps you add a complete real-time messaging system to your new / existing application with only one command.

A Laravel package helps you add a complete real-time messaging system to your new / existing application with only one command.

Munaf Aqeel Mahdi 1.7k Jan 5, 2023
📦 Adds Laravel Packages Support to Lumen and Vendor Publish Artisan Command.

Laravel Package Support for Lumen: Makes Lumen compatible with Laravel Packages. You can use any Laravel Packages in Lumen by installing Larasupport Package.

Irfaq Syed 127 Dec 17, 2022
Create Laravel views (blade template) using 'php artisan' command-line interface

About LaraBit Have you ever wonder to create Laravel views (Blade Templates) using the same type of artisan commands that you usually use to create ne

Ragib MRB 5 Oct 15, 2021
Generate services in Laravel with the artisan command

Laravel Service Generator Quickly generate services for your projects! Table of Contents Features Installation Usage Generate services Generate servic

Tim Wassenburg 15 Dec 2, 2022
An artisan command for using multiple environment configurations in Laravel 5

Laravel 5 env An artisan command for managing multiple .env of your Laravel 5 app. Installation Copy EnvCommand.php to app/Console/Commands/ of your L

Tommy Ku 18 Nov 29, 2022
Generate services and contracts in Laravel with the artisan command

What does it do? This package adds a new php artisan make:service {name} {--N|noContract} command. It will create a service file and its contract (int

Ludovic Guénet 18 Dec 21, 2022
Make your Laravel app comply with the crazy EU cookie law

Make your Laravel app comply with the crazy EU cookie law All sites owned by EU citizens or targeted towards EU citizens must comply with a crazy EU l

Spatie 1.2k Jan 4, 2023
A package to easily make use of Iconic icons in your Laravel Blade views.

Blade Iconic A package to easily make use of Iconic icons in your Laravel Blade views. For a full list of available icons see the SVG directory. Iconi

Malik Alleyne-Jones 17 Aug 25, 2022
A package to easily make use of Simple Icons in your Laravel Blade views.

Blade Simple Icons A package to easily make use of Simple Icons in your Laravel Blade views. For a full list of available icons see the SVG directory.

UB Labs 12 Jan 17, 2022
Make your Laravel app comply with the refuse/accept cookie law

Make your Laravel app comply with the refuse/accept cookie law All sites owned by EU citizens or targeted towards EU citizens must comply with a crazy

RETINENS - Multimedia solutions 37 Mar 22, 2022
This package gives you a set of conventions to make the most out of Hotwire in Laravel

Introduction This package gives you a set of conventions to make the most out of Hotwire in Laravel (inspired by the turbo-rails gem). There is a comp

Tony Messias 665 Jan 2, 2023