MCPcopy Index your code
hub / github.com/conventionalcommit/commitlint / getConfig

Function getConfig

internal/cmd/lint.go:83–96  ·  view source on GitHub ↗
(confParam string)

Source from the content-addressed store, hash-verified

81}
82
83func getConfig(confParam string) (*lint.Config, error) {
84 if confParam != "" {
85 confParam = filepath.Clean(confParam)
86 return config.Parse(confParam)
87 }
88
89 // If config param is empty, lookup for defaults
90 conf, err := config.LookupAndParse()
91 if err != nil {
92 return nil, err
93 }
94
95 return conf, nil
96}
97
98func getCommitMsg(fileInput string) (string, error) {
99 commitMsg, err := readStdInPipe()

Callers 1

getLinterFunction · 0.85

Calls 2

ParseFunction · 0.92
LookupAndParseFunction · 0.92

Tested by

no test coverage detected