Semaphore/lib/GitClientFactory.go
2023-07-23 16:18:02 +02:00

23 lines
426 B
Go

package lib
import "github.com/ansible-semaphore/semaphore/util"
func CreateDefaultGitClient() GitClient {
switch util.Config.GitClientId {
case util.GoGitClientId:
return CreateGoGitClient()
case util.CmdGitClientId:
return CreateCmdGitClient()
default:
return CreateCmdGitClient()
}
}
func CreateGoGitClient() GitClient {
return GoGitClient{}
}
func CreateCmdGitClient() GitClient {
return CmdGitClient{}
}