aboutsummaryrefslogtreecommitdiffstats
path: root/lua/alpha/laravel/init.lua
diff options
context:
space:
mode:
authorAriel D'Alessandro <dalessandro.ariel@gmail.com>2022-08-05 09:02:11 +0200
committerAriel D'Alessandro <dalessandro.ariel@gmail.com>2022-08-05 09:02:55 +0200
commit67f55ef388b18310c06219eb3207ba513673127a (patch)
treee1dc45f9b52ed39369f451ab5ac4ddcf30e5aa3e /lua/alpha/laravel/init.lua
parent0c6c7768eb0fe0fd496c936ecb348c694180fc1a (diff)
downloadnvim-conf-67f55ef388b18310c06219eb3207ba513673127a.tar.gz
nvim-conf-67f55ef388b18310c06219eb3207ba513673127a.zip
add temporary laravel plugin scratch
Diffstat (limited to 'lua/alpha/laravel/init.lua')
-rw-r--r--lua/alpha/laravel/init.lua42
1 files changed, 42 insertions, 0 deletions
diff --git a/lua/alpha/laravel/init.lua b/lua/alpha/laravel/init.lua
new file mode 100644
index 0000000..c8ee711
--- /dev/null
+++ b/lua/alpha/laravel/init.lua
@@ -0,0 +1,42 @@
+vim.api.nvim_create_user_command("Artisan", function ()
+ local artisan_config = require("alpha.laravel.artisan_config")
+ if artisan_config.is_laravel then
+ require("alpha.laravel.telescope").picker({})
+ end
+end, {})
+
+-- TODO
+-- move it as plugin folder
+-- Add setup fuction and set the global function like "Artisan" or something like that
+-- add code actions to create a model
+-- or create controller
+-- or create any class
+-- hover a class the actions could be call the make for that
+-- trigger the completition
+--
+--
+-- more searches on telescope or somthing
+-- package laravel.nvim
+--
+-- require("laravel").setup() || initializes the global variable
+
+-- uses the global variable so not to recheck the composer and more
+--
+-- require("laravel.artisan").run("route:list", {<args>})
+-- require("laravel.artisan").make("controller", {<args>})
+-- require("laravel.artisan").list() || return the list of commands, mostly to be use as telescope entries
+-- require("laravel.artisan").help(<cmd>) || return the help for the command
+-- require("laravel.artisan").watch_test("filename") || this will run auto cmd for php files and write.
+--
+-- can open a new buffer, replace the buffer on the window, delete the previous buffer, put response on the new buffer
+--
+-- require("laravel.sail").run("<cmd>")
+--
+-- require("laravel.composer").udpate("library") || optional field
+-- require("laravel.composer").install()
+-- require("laravel.composer").require()
+-- require("laravel.composer").remove()
+--
+--
+-- User commands
+-- Could register the user commands for Artisan Sail & Composer