feat: automatic module directories (#1315)

This commit is contained in:
Ludovic Fernandez
2025-11-21 16:03:27 +01:00
committed by GitHub
parent f3ae99f5f5
commit e7fa5ac41e
18 changed files with 541 additions and 275 deletions

3
sample-monorepo/a/go.mod Normal file
View File

@@ -0,0 +1,3 @@
module github.com/golangci/actiona
go 1.24.0

View File

@@ -0,0 +1,26 @@
// Package sample is used as test input for golangci action.
package sample
import (
"crypto/md5"
"encoding/hex"
"errors"
)
// Hash~
func Hash(data string) string {
retError()
retError2()
h := md5.New()
h.Write([]byte(data))
return hex.EncodeToString(h.Sum(nil))
}
func retError() error {
return errors.New("err")
}
func retError2() error {
return errors.New("err2")
}

View File

@@ -0,0 +1,3 @@
module github.com/golangci/actiona/suba
go 1.24.0

View File

@@ -0,0 +1,26 @@
// Package sample is used as test input for golangci action.
package sample
import (
"crypto/md5"
"encoding/hex"
"errors"
)
// Hash~
func Hash(data string) string {
retError()
retError2()
h := md5.New()
h.Write([]byte(data))
return hex.EncodeToString(h.Sum(nil))
}
func retError() error {
return errors.New("err")
}
func retError2() error {
return errors.New("err2")
}