mirror of
https://github.com/golangci/golangci-lint-action.git
synced 2026-04-14 07:46:54 +00:00
add sample
This commit is contained in:
parent
60b57697f8
commit
6eb54d49f7
3 changed files with 31 additions and 0 deletions
14
sample/sample.go
Normal file
14
sample/sample.go
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
// Package sample is used as test input for golangci action.
|
||||
package sample
|
||||
|
||||
import (
|
||||
"crypto/md5"
|
||||
"encoding/hex"
|
||||
)
|
||||
|
||||
// Hash~
|
||||
func Hash(data string) string {
|
||||
h := md5.New()
|
||||
h.Write([]byte(data))
|
||||
return hex.EncodeToString(h.Sum(nil))
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue