Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 19 Feb 2018 16:34:23 +0000 (UTC)
From:      Kyle Evans <kevans@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r329585 - head/stand/lua
Message-ID:  <201802191634.w1JGYNAE003191@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: kevans
Date: Mon Feb 19 16:34:23 2018
New Revision: 329585
URL: https://svnweb.freebsd.org/changeset/base/329585

Log:
  stand/lua: Add core.isSingleUserBoot

Modified:
  head/stand/lua/core.lua

Modified: head/stand/lua/core.lua
==============================================================================
--- head/stand/lua/core.lua	Mon Feb 19 16:31:19 2018	(r329584)
+++ head/stand/lua/core.lua	Mon Feb 19 16:34:23 2018	(r329585)
@@ -191,6 +191,11 @@ function core.boot()
 	loader.perform("boot");
 end
 
+function core.isSingleUserBoot()
+	local single_user = loader.getenv("boot_single");
+	return single_user ~= nil and single_user:lower() == "yes";
+end
+
 function core.isSerialBoot()
 	local c = loader.getenv("console");
 



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201802191634.w1JGYNAE003191>