diff --git a/common/version.c b/common/version.c index 928cff32f..f90df212f 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 4445a671d..d6c1ad5db 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 77e408831..c24af8084 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\"");