mirror of
https://github.com/yonaskolb/XcodeGen.git
synced 2026-03-18 20:02:25 +00:00
Use USER env var instead of LOGNAME (#1559)
During user switch with su/sudo in system LOGNAME may not be initialised, but USER env var is always exist.
This commit is contained in:
committed by
GitHub
parent
c32aa4cc94
commit
38d76e7fa1
@@ -100,7 +100,7 @@ class GenerateCommand: ProjectCommand {
|
||||
do {
|
||||
let projectGenerator = ProjectGenerator(project: project)
|
||||
|
||||
guard let userName = ProcessInfo.processInfo.environment["LOGNAME"] else {
|
||||
guard let userName = ProcessInfo.processInfo.environment["USER"] else {
|
||||
throw GenerationError.missingUsername
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user