From 3af5bc2df5b865dcc6770d1b8ee4c8c4c6aa959f Mon Sep 17 00:00:00 2001 From: Adam Harrison Date: Sat, 3 Dec 2022 16:06:03 -0500 Subject: Also adding in mode. --- src/lpm.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/lpm.c b/src/lpm.c index fbb5981..5c39f41 100644 --- a/src/lpm.c +++ b/src/lpm.c @@ -260,6 +260,7 @@ static int lpm_stat(lua_State *L) { #endif lua_pushinteger(L, s.st_mtime); lua_setfield(L, -2, "modified"); lua_pushinteger(L, s.st_size); lua_setfield(L, -2, "size"); + lua_pushinteger(L, s.st_mode); lua_setfield(L, -2, "mode"); if (S_ISREG(s.st_mode)) { lua_pushstring(L, "file"); } else if (S_ISDIR(s.st_mode)) { -- cgit v1.2.3