From 96194fb33f6fc2ce00381458d5c08e5eebc9f329 Mon Sep 17 00:00:00 2001 From: 10sr <8slashes+git@gmail.com> Date: Mon, 31 Oct 2016 10:20:51 +0900 Subject: [PATCH] Update init.lua --- micro/init.lua | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/micro/init.lua b/micro/init.lua index 1422e4e..46185ec 100644 --- a/micro/init.lua +++ b/micro/init.lua @@ -6,9 +6,18 @@ function onViewOpen(view) local filename = view.Buf.Path -- prop, names = ec.parse(filepath) local fullpath = JoinPaths(pwd, filename) - messenger:Message("view.Buf.Path: " .. fullpath) + local out = getProperties(fullpath) + messenger:Message("view.Buf.Path: " .. out) end +local function getProperties(fullpath) + local file = io.popen("echo fullpath: " .. fullpath, "r") + local output = file:read("*all") + file:close() + return output +end + + function onSave(view) messenger:Message("Saved!") end