Running superlinter as a user not defined in /etc/passwd causes error messages (#4351)

* no need to run git check-ignore on every file if you are not setting IGNORE_GITIGNORED_FILES

* use id instead of whoami for determining running and discard stderr

* accidently include change from other PR

* remove commented code

---------

Co-authored-by: Zack Koppert <zkoppert@github.com>
This commit is contained in:
Stephen Abbene 2023-06-20 12:57:38 -07:00 committed by GitHub
parent dea6e50722
commit 35d5a3e9fb
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -213,7 +213,7 @@ function GetValidationInfo() {
debug "--- DEBUG INFO ---" debug "--- DEBUG INFO ---"
debug "---------------------------------------------" debug "---------------------------------------------"
RUNNER=$(whoami) RUNNER=$(id -un 2>/dev/null)
debug "Runner:[${RUNNER}]" debug "Runner:[${RUNNER}]"
PRINTENV=$(printenv | sort) PRINTENV=$(printenv | sort)
debug "ENV:" debug "ENV:"