Comparison

util/dependencies.lua @ 2146:5c54097ef84a

util.dependencies: Make the commands line up properly in the "missing dependency" output. Yes, this was the commit you didn't know you were waiting for!
author Matthew Wild <mwild1@gmail.com>
date Mon, 23 Nov 2009 02:58:42 +0000
parent 1523:841d61be198f
child 2160:0ef04962e112
comparison
equal deleted inserted replaced
2145:daeb6ebf304c 2146:5c54097ef84a
15 print(""); 15 print("");
16 print("**************************"); 16 print("**************************");
17 print("Prosody was unable to find "..tostring(name)); 17 print("Prosody was unable to find "..tostring(name));
18 print("This package can be obtained in the following ways:"); 18 print("This package can be obtained in the following ways:");
19 print(""); 19 print("");
20 for k,v in pairs(sources) do 20 local longest_platform = 0;
21 print("", k, v); 21 for platform in pairs(sources) do
22 longest_platform = math.max(longest_platform, #platform);
23 end
24 for platform, source in pairs(sources) do
25 print("", platform..":"..(" "):rep(4+longest_platform-#platform)..source);
22 end 26 end
23 print(""); 27 print("");
24 print(msg or (name.." is required for Prosody to run, so we will now exit.")); 28 print(msg or (name.." is required for Prosody to run, so we will now exit."));
25 print("More help can be found on our website, at http://prosody.im/doc/depends"); 29 print("More help can be found on our website, at http://prosody.im/doc/depends");
26 print("**************************"); 30 print("**************************");