Interacting with Artisan - noahfrederick/vim-laravel Wiki

Original URL:

The :Artisan command makes it easy to interact with Laravel's artisan from Vim's command line with smart completion of subcommands and flags. Note that :Artisan doesn't care about your current working directory, only about whether the current buffer's file belongs to a Laravel project.

Laravel's generators (e.g., artisan make:controller) have special integration with :Artisan, which will automatically load the generated file into a buffer.


The :Artisan command shells out to php artisan by default. If you have a containerized setup, such as if you are using Laravel Sail, you can customize the executable name:

let g:laravel_artisan = 'sail artisan'