From 06fac9a1517044a7cc2434702dc999c359298d76 Mon Sep 17 00:00:00 2001 From: Julien Danjou Date: Thu, 31 Jul 2008 17:48:27 +0200 Subject: [PATCH] lua: stop using version_string() Signed-off-by: Julien Danjou --- common/version.c | 9 --------- common/version.h | 1 - lua.c | 4 ++-- 3 files changed, 2 insertions(+), 12 deletions(-) diff --git a/common/version.c b/common/version.c index 928cff32..f90df212 100644 --- a/common/version.c +++ b/common/version.c @@ -66,13 +66,4 @@ eprint_version(const char *const executable) exit(EXIT_SUCCESS); } -/** Get version string. - * \return A string describing the current version. - */ -const char* -version_string(void) -{ - return AWESOME_VERSION; -} - // vim: filetype=c:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:encoding=utf-8:textwidth=80 diff --git a/common/version.h b/common/version.h index 4445a671..d6c1ad5d 100644 --- a/common/version.h +++ b/common/version.h @@ -23,6 +23,5 @@ #define AWESOME_COMMON_VERSION_H void eprint_version(const char *const executable) __attribute__ ((noreturn)); -const char *version_string(void); #endif diff --git a/lua.c b/lua.c index 77e40883..c24af808 100644 --- a/lua.c +++ b/lua.c @@ -34,6 +34,7 @@ #include #include +#include "awesome-version-internal.h" #include "ewmh.h" #include "config.h" #include "lua.h" @@ -44,7 +45,6 @@ #include "screen.h" #include "layouts/tile.h" #include "common/socket.h" -#include "common/version.h" extern awesome_t globalconf; @@ -515,7 +515,7 @@ luaA_init(void) luaA_openlib(L, "keybinding", awesome_keybinding_methods, awesome_keybinding_meta); lua_pushliteral(L, "AWESOME_VERSION"); - lua_pushstring(L, version_string()); + lua_pushstring(L, AWESOME_VERSION); lua_settable(L, LUA_GLOBALSINDEX); luaA_dostring(L, "package.path = package.path .. \";" AWESOME_LUA_LIB_PATH "/?.lua\"");