Skip to content

Commit

Permalink
Set git gpg.program if possible (#464)
Browse files Browse the repository at this point in the history
Fixes #451
  • Loading branch information
dominikschulz authored Nov 13, 2017
1 parent a151856 commit 6508b5b
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 31 deletions.
9 changes: 8 additions & 1 deletion backend/git/cli/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,14 @@ func (g *Git) fixConfig(ctx context.Context) error {
out.Yellow(ctx, "Error while initializing git: %s", err)
}

return g.fixConfigOSDep(ctx)
if g.gpg == "" {
return nil
}

if err := g.Cmd(ctx, "gitFixConfig", "config", "--local", "gpg.program", g.gpg); err != nil {
return errors.Wrapf(err, "failed to set git config gpg.program")
}
return nil
}

// InitConfig initialized and preparse the git config
Expand Down
10 changes: 0 additions & 10 deletions backend/git/cli/config_others.go

This file was deleted.

20 changes: 0 additions & 20 deletions backend/git/cli/config_windows.go

This file was deleted.

0 comments on commit 6508b5b

Please sign in to comment.