mirror of
https://github.com/kubernetes-csi/csi-driver-nvmf.git
synced 2025-08-02 06:31:59 +00:00
Commit summary:
1fbad65
Squashed 'release-tools/' changes from f9d5b9c..98f2307
Signed-off-by: Terry Howe <terrylhowe@gmail.com>
20 lines
241 B
Go
20 lines
241 B
Go
//go:build !windows
|
|
// +build !windows
|
|
|
|
package klog
|
|
|
|
import (
|
|
"os/user"
|
|
)
|
|
|
|
func getUserName() string {
|
|
userNameOnce.Do(func() {
|
|
current, err := user.Current()
|
|
if err == nil {
|
|
userName = current.Username
|
|
}
|
|
})
|
|
|
|
return userName
|
|
}
|