|
1 | | --- each element represent a command that after execution should open a file |
2 | | --- if the return is a string is use as directory to search file. |
3 | | --- if the return is a function will call and expects the result to be an string |
4 | 1 | return { |
5 | | - ["make:cast"] = "app/Casts", |
6 | | - ["make:channel"] = "app/Broadcasting", |
7 | | - ["make:command"] = "app/Console/Commands", |
8 | | - ["make:component"] = "app/View/Components", |
9 | | - ["make:controller"] = "app/Http/Controllers", |
10 | | - ["make:event"] = "app/Events", |
11 | | - ["make:exception"] = "app/Exceptions", |
12 | | - ["make:factory"] = function(name) |
13 | | - return string.format("database/factories/%sFactory.php", name) |
14 | | - end, |
15 | | - ["make:job"] = "app/Jobs", |
16 | | - ["make:listener"] = "app/Listeners", |
17 | | - ["make:mail"] = "app/Mail", |
18 | | - ["make:middleware"] = "app/Http/Middleware", |
19 | | - ["make:migration"] = function(name) |
20 | | - return vim.fn.systemlist(string.format("fd %s.php", name))[1] |
21 | | - end, |
22 | | - ["make:model"] = "app/Models", |
23 | | - ["make:notification"] = "app/Notifications", |
24 | | - ["make:observer"] = "app/Observers", |
25 | | - ["make:policy"] = "app/Policies", |
26 | | - ["make:provider"] = "app/Providers", |
27 | | - ["make:request"] = "app/Http/Requests", |
28 | | - ["make:resource"] = "app/Http/Resources", |
29 | | - ["make:rule"] = "app/Rules", |
30 | | - ["make:scope"] = "app/Models/Scopes", |
31 | | - ["make:seeder"] = "database/seeders", |
32 | | - ["make:test"] = "tests/Feature", |
33 | | - ["make:view"] = function(name) |
34 | | - return "resources/views/" .. name:gsub("%.", "/") .. ".blade.php" |
35 | | - end, |
| 2 | + ["Controllers"] = "app/Http/Controllers", |
| 3 | + ["Livewire"] = "app/Livewire", |
| 4 | + ["Models"] = "app/Models", |
| 5 | + ["Views"] = "resources/views", |
| 6 | + ["Migrations"] = "database/migrations", |
| 7 | + ["Providers"] = "app/Providers", |
| 8 | + ["Components"] = "app/View/Components", |
| 9 | + ["Routes"] = "routes", |
| 10 | + ["Factories"] = "database/factories", |
| 11 | + ["Seeders"] = "database/seeders", |
| 12 | + ["Configs"] = "config", |
| 13 | + ["FeatureTest"] = "tests/Feature", |
| 14 | + ["UnitTest"] = "tests/Unit", |
| 15 | + ["Requests"] = "app/Http/Requests", |
36 | 16 | } |
0 commit comments