summaryrefslogtreecommitdiff
path: root/lua/utility/misc.lua
diff options
context:
space:
mode:
Diffstat (limited to 'lua/utility/misc.lua')
-rw-r--r--lua/utility/misc.lua8
1 files changed, 8 insertions, 0 deletions
diff --git a/lua/utility/misc.lua b/lua/utility/misc.lua
new file mode 100644
index 0000000..04ec1fc
--- /dev/null
+++ b/lua/utility/misc.lua
@@ -0,0 +1,8 @@
+function GetCurrentFile()
+ return vim.fn.expand("%")
+end
+
+function Dirname(file_path)
+ return vim.fn.fnamemodify(file_path, ":p:h")
+end
+