aboutsummaryrefslogtreecommitdiffstats
path: root/after/plugin/workspaces.lua
diff options
context:
space:
mode:
authorAriel D'Alessandro <dalessandro.ariel@gmail.com>2022-08-11 08:39:41 +0200
committerAriel D'Alessandro <dalessandro.ariel@gmail.com>2022-08-11 08:39:41 +0200
commita6eb3f300d3237fa111e30fa21b5084ed7636327 (patch)
treeca893f2a6d3e304152f872ce9181dfb5d9a7b2a9 /after/plugin/workspaces.lua
parentf61af678dd5da523340c71f57eb95d8d8a76d780 (diff)
downloadnvim-conf-a6eb3f300d3237fa111e30fa21b5084ed7636327.tar.gz
nvim-conf-a6eb3f300d3237fa111e30fa21b5084ed7636327.zip
updates on libraries
Diffstat (limited to 'after/plugin/workspaces.lua')
-rw-r--r--after/plugin/workspaces.lua43
1 files changed, 43 insertions, 0 deletions
diff --git a/after/plugin/workspaces.lua b/after/plugin/workspaces.lua
new file mode 100644
index 0000000..45df9af
--- /dev/null
+++ b/after/plugin/workspaces.lua
@@ -0,0 +1,43 @@
+-- local ok, workspaces = pcall(require, "workspaces")
+-- if not ok then
+-- return
+-- end
+
+-- local scandir = require("plenary.scandir")
+
+
+-- require("sessions").setup({
+-- events = {"WinEnter", "BufEnter", "BufWritePost" },
+-- session_filepath = ".nvim/session",
+-- })
+-- workspaces.setup({
+-- hooks = {
+-- open = function()
+-- require("sessions").load(nil, { silent = true })
+-- end,
+-- }
+-- })
+
+
+-- local ws = workspaces.get()
+-- local function workspace_exists(name)
+-- for _, workspace in ipairs(ws) do
+-- if workspace.name == name then
+-- return true
+-- end
+-- end
+-- return false
+-- end
+
+
+-- local dirs = scandir.scan_dir(
+-- { "/home/alpha/code/php" },
+-- { depth = 1, only_dirs = true }
+-- )
+
+-- for _, path in ipairs(dirs) do
+-- local name = "[PHP]" .. vim.fs.basename(path)
+-- if not workspace_exists(name) then
+-- workspaces.add(name, path)
+-- end
+-- end