aboutsummaryrefslogtreecommitdiff
path: root/lua/pets/commands.lua
diff options
context:
space:
mode:
Diffstat (limited to 'lua/pets/commands.lua')
-rw-r--r--lua/pets/commands.lua9
1 files changed, 9 insertions, 0 deletions
diff --git a/lua/pets/commands.lua b/lua/pets/commands.lua
new file mode 100644
index 0000000..8124cbc
--- /dev/null
+++ b/lua/pets/commands.lua
@@ -0,0 +1,9 @@
+local pets = require("pets")
+
+vim.api.nvim_create_user_command("Pets", function()
+ pets.show()
+end, {}) -- use nargs = 1 to accept arguments
+
+vim.api.nvim_create_user_command("PetsCloseAll", function()
+ pets.closeAll()
+end, {})