From owner-dev-commits-src-branches@freebsd.org Sun Jan 24 06:13:40 2021 Return-Path: Delivered-To: dev-commits-src-branches@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 74C5D4EFDEB; Sun, 24 Jan 2021 06:13:40 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4DNjP02vV9z4Ztd; Sun, 24 Jan 2021 06:13:40 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 567111EBD3; Sun, 24 Jan 2021 06:13:40 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 10O6De2T062809; Sun, 24 Jan 2021 06:13:40 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 10O6DeTm062808; Sun, 24 Jan 2021 06:13:40 GMT (envelope-from git) Date: Sun, 24 Jan 2021 06:13:40 GMT Message-Id: <202101240613.10O6DeTm062808@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kyle Evans Subject: git: 0b97b9ae187f - stable/12 - lualoader: fix lua-lint run MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kevans X-Git-Repository: src X-Git-Refname: refs/heads/stable/12 X-Git-Reftype: branch X-Git-Commit: 0b97b9ae187fe02348b1b4000f964aaa257b1edf Auto-Submitted: auto-generated X-BeenThere: dev-commits-src-branches@freebsd.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Commits to the stable branches of the FreeBSD src repository List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 24 Jan 2021 06:13:40 -0000 The branch stable/12 has been updated by kevans: URL: https://cgit.FreeBSD.org/src/commit/?id=0b97b9ae187fe02348b1b4000f964aaa257b1edf commit 0b97b9ae187fe02348b1b4000f964aaa257b1edf Author: Kyle Evans AuthorDate: 2020-12-17 18:29:30 +0000 Commit: Kyle Evans CommitDate: 2021-01-24 06:13:03 +0000 lualoader: fix lua-lint run luacheck rightfully complains that i is unused in the show-module-options loop at the end (it was used for some debugging in the process). We've added a new pager module that's compiled in, so declare that as an acceptable global. (cherry picked from commit 29842cb36e74037989b7a7f0bf38a47f342bac91) --- stand/lua/cli.lua | 2 +- tools/boot/lua-lint.sh | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/stand/lua/cli.lua b/stand/lua/cli.lua index d1947ca1021d..b7581c985a75 100644 --- a/stand/lua/cli.lua +++ b/stand/lua/cli.lua @@ -234,7 +234,7 @@ cli["show-module-options"] = function() end pager.open() - for i, v in ipairs(lines) do + for _, v in ipairs(lines) do pager.output(v .. "\n") end pager.close() diff --git a/tools/boot/lua-lint.sh b/tools/boot/lua-lint.sh index cc7a007947f2..c6bc89da3330 100755 --- a/tools/boot/lua-lint.sh +++ b/tools/boot/lua-lint.sh @@ -17,4 +17,5 @@ LUACHECK=$(which luacheck) cd $(make -V SRCTOP)/stand ${LUACHECK} . --globals loader --globals lfs --globals io.getchar \ --globals io.ischar --globals printc --globals cli_execute \ - --globals cli_execute_unparsed --globals try_include --std lua53 + --globals cli_execute_unparsed --globals try_include \ + --globals pager --std lua53