We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent e4537b1 commit f7cf4cbCopy full SHA for f7cf4cb
cmd/root.go
@@ -41,11 +41,12 @@ func (gf globalFlags) WorkingEnvSpec() types.WorkingEnvSpec {
41
GhostRepo: gf.ghostRepo,
42
}
43
userName, userEmail, err := git.GetUserConfig(globalOpts.srcDir)
44
- if err != nil {
+ if err == nil {
45
+ workingEnvSpec.GhostUserName = userName
46
+ workingEnvSpec.GhostUserEmail = userEmail
47
+ } else {
48
log.Debug("failed to get user name and email of the source directory")
49
- workingEnvSpec.GhostUserName = userName
- workingEnvSpec.GhostUserEmail = userEmail
50
return workingEnvSpec
51
52
0 commit comments