squish.lua

changeset 71
e27ab4492cdd
parent 67
2fc48318b8bb
child 80
b70f75414c81
--- a/squish.lua	Thu Jul 08 01:14:51 2010 +0100
+++ b/squish.lua	Fri Aug 06 20:17:46 2010 +0100
@@ -215,7 +215,10 @@
 
 print_verbose("Packing modules...");
 for _, module in ipairs(modules) do
-	local modulename, path = module.name, base_path..module.path;
+	local modulename, path = module.name, module.path;
+	if module.path:sub(1,1) ~= "/" then
+		path = base_path..module.path;
+	end
 	print_debug("Packing "..modulename.." ("..path..")...");
 	local data, err = fetch.filesystem(path);
 	if (not data) and module.url then

mercurial