# HG changeset patch # User Matthew Wild # Date 1258129953 0 # Node ID b3889bfb60520f42c39b3e2ee820176f1ccee565 # Parent 140ff9cafe2f087eff11de2fb6d18dfd56bca22e Add README and COPYING files diff -r 140ff9cafe2f -r b3889bfb6052 COPYING --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/COPYING Fri Nov 13 16:32:33 2009 +0000 @@ -0,0 +1,20 @@ +Copyright (c) 2008-2009 Matthew Wild +Copyright (c) 2008-2009 Waqas Hussain + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff -r 140ff9cafe2f -r b3889bfb6052 README --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/README Fri Nov 13 16:32:33 2009 +0000 @@ -0,0 +1,14 @@ +lua2html... another one. Feel free to suggest a more original name :) + +This script is the one I use for HTML-ifying my Lua scripts. Its goal isn't full syntax colouring of +Lua, but this version has some more useful features. + +Global variables are highlighted in red, and even stronger when they are being set. Upvalues are highlighted in green. + +It can also read in coverage reports from my homegrown unit tester. They are in the format: + +test_sasl.lua|30||true +test_sasl.lua|31||miss + +The first column is the filename, then the line number, and the last column is 'true' (line passed all tests), 'false' +(line failed one more tests) or 'miss' to indicate the line wasn't tested. Don't ask what the empty column is, I forgot :) diff -r 140ff9cafe2f -r b3889bfb6052 lua2html.lua --- a/lua2html.lua Fri Nov 13 16:24:48 2009 +0000 +++ b/lua2html.lua Fri Nov 13 16:32:33 2009 +0000 @@ -1,3 +1,7 @@ +-- Copyright (C) 2008-2009 Matthew Wild +-- +-- This project is MIT/X11 licensed. Please see the +-- COPYING file in the source package for more information. local keywords = { "function", "for", "if", "elseif", "then", "else", "do", "repeat", "until", "end", "return", "true", "false", "and", "not", "or", "local", "nil", "break" } for _, keyword in ipairs(keywords) do keywords[keyword] = true; end