Skip to content

Commit 77282dc

Browse files
committed
remove useless
1 parent 35ce85b commit 77282dc

File tree

1 file changed

+0
-18
lines changed

1 file changed

+0
-18
lines changed

scripts/go-copyright/main.go

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@
1313
package main
1414

1515
import (
16-
"encoding/json"
1716
"fmt"
1817
"go/ast"
1918
"go/parser"
@@ -137,23 +136,6 @@ func isGenerated(fset *token.FileSet, file *ast.File) bool {
137136
return false
138137
}
139138

140-
func loadIgnoreFiles() []string {
141-
const cfgfile = ".licenserc.json"
142-
byts, err := os.ReadFile(cfgfile)
143-
if err != nil {
144-
return nil
145-
}
146-
var config struct {
147-
Ignore []string `json:"ignore"`
148-
}
149-
err = json.Unmarshal(byts, &config)
150-
if err != nil {
151-
fmt.Println(fmt.Errorf("fail to parse %s", cfgfile))
152-
os.Exit(1)
153-
}
154-
return config.Ignore
155-
}
156-
157139
func main() {
158140
files, err := checkCopyright()
159141
if err != nil {

0 commit comments

Comments
 (0)