Software /
code /
prosody
Diff
tools/jabberd14sql2prosody.lua @ 5696:9fba74a28e0c
package{,c}path fixes for migration tools
author | Vadim Misbakh-Soloviov <mva@mva.name> |
---|---|
date | Fri, 14 Jun 2013 15:15:05 +0700 |
parent | 5216:63db6f281708 |
child | 5776:bd0ff8ae98a8 |
child | 6147:852bd69ba148 |
line wrap: on
line diff
--- a/tools/jabberd14sql2prosody.lua Thu Jun 13 23:24:36 2013 +0100 +++ b/tools/jabberd14sql2prosody.lua Fri Jun 14 15:15:05 2013 +0700 @@ -428,7 +428,14 @@ end -- import modules -package.path = [[C:\Documents and Settings\Waqas\Desktop\mercurial\prosody-hg\?.lua;]]..package.path; +package.path = package.path.."..\?.lua;"; + +local my_name = arg[0]; +if my_name:match("[/\\]") then + package.path = package.path..";"..my_name:gsub("[^/\\]+$", "../?.lua"); + package.cpath = package.cpath..";"..my_name:gsub("[^/\\]+$", "../?.so"); +end + -- ugly workaround for getting datamanager to work outside of prosody :( prosody = { };