From 2d2c189a665f4ece15d3f4fee4dbcb89208d409d Mon Sep 17 00:00:00 2001 From: Gregor Hartmann Date: Mon, 16 Jul 2018 07:48:47 +0200 Subject: [PATCH] Add checking of Lua sources to travis build (#2423) --- lua_examples/lfs/lfs_fragments.lua | 2 +- lua_examples/mqtt/mqtt_file.lua | 2 +- tools/pr-build.sh | 4 ++++ 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/lua_examples/lfs/lfs_fragments.lua b/lua_examples/lfs/lfs_fragments.lua index 83f70f2a..8863b230 100644 --- a/lua_examples/lfs/lfs_fragments.lua +++ b/lua_examples/lfs/lfs_fragments.lua @@ -7,7 +7,7 @@ do local _,ma,fa=node.flashindex() for n,v in pairs{LFS_MAPPED=ma, LFS_BASE=fa, SPIFFS_BASE=sa} do - print(('export %s=""0x%x"'):format(n, v) + print(('export %s=""0x%x"'):format(n, v)) end end -- diff --git a/lua_examples/mqtt/mqtt_file.lua b/lua_examples/mqtt/mqtt_file.lua index 6d0d88e4..4d192325 100644 --- a/lua_examples/mqtt/mqtt_file.lua +++ b/lua_examples/mqtt/mqtt_file.lua @@ -43,7 +43,7 @@ m:on("offline", function(conn) end) m:on("message",dispatch ) -- Lua: mqtt:connect( host, port, secure, auto_reconnect, function(client) ) -m:connect(192.168.18.88,1883,0,1) +m:connect("192.168.18.88",1883,0,1) -- usage: -- another client(pc) subscribe to /topic2, will receive the test.lua content. diff --git a/tools/pr-build.sh b/tools/pr-build.sh index f7866f71..0670c741 100644 --- a/tools/pr-build.sh +++ b/tools/pr-build.sh @@ -29,4 +29,8 @@ cd "$TRAVIS_BUILD_DIR"/ld || exit cd "$TRAVIS_BUILD_DIR" || exit make clean make + +LUA_FILES=`find lua_modules lua_examples -iname "*.lua"` +echo checking $LUA_FILES +./luac.cross -p $LUA_FILES )