lua: stop using version_string()

Signed-off-by: Julien Danjou <julien@danjou.info>
This commit is contained in:
Julien Danjou 2008-07-31 17:48:27 +02:00
parent e0abfac892
commit 06fac9a151
3 changed files with 2 additions and 12 deletions

View File

@ -66,13 +66,4 @@ eprint_version(const char *const executable)
exit(EXIT_SUCCESS); 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 // vim: filetype=c:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:encoding=utf-8:textwidth=80

View File

@ -23,6 +23,5 @@
#define AWESOME_COMMON_VERSION_H #define AWESOME_COMMON_VERSION_H
void eprint_version(const char *const executable) __attribute__ ((noreturn)); void eprint_version(const char *const executable) __attribute__ ((noreturn));
const char *version_string(void);
#endif #endif

4
lua.c
View File

@ -34,6 +34,7 @@
#include <xcb/xcb.h> #include <xcb/xcb.h>
#include <xcb/xcb_aux.h> #include <xcb/xcb_aux.h>
#include "awesome-version-internal.h"
#include "ewmh.h" #include "ewmh.h"
#include "config.h" #include "config.h"
#include "lua.h" #include "lua.h"
@ -44,7 +45,6 @@
#include "screen.h" #include "screen.h"
#include "layouts/tile.h" #include "layouts/tile.h"
#include "common/socket.h" #include "common/socket.h"
#include "common/version.h"
extern awesome_t globalconf; extern awesome_t globalconf;
@ -515,7 +515,7 @@ luaA_init(void)
luaA_openlib(L, "keybinding", awesome_keybinding_methods, awesome_keybinding_meta); luaA_openlib(L, "keybinding", awesome_keybinding_methods, awesome_keybinding_meta);
lua_pushliteral(L, "AWESOME_VERSION"); lua_pushliteral(L, "AWESOME_VERSION");
lua_pushstring(L, version_string()); lua_pushstring(L, AWESOME_VERSION);
lua_settable(L, LUA_GLOBALSINDEX); lua_settable(L, LUA_GLOBALSINDEX);
luaA_dostring(L, "package.path = package.path .. \";" AWESOME_LUA_LIB_PATH "/?.lua\""); luaA_dostring(L, "package.path = package.path .. \";" AWESOME_LUA_LIB_PATH "/?.lua\"");