mirror of
				https://gitee.com/gitea/gitea
				synced 2025-11-04 16:40:24 +08:00 
			
		
		
		
	Add golangci (#6418)
This commit is contained in:
		@@ -7,7 +7,6 @@ package git
 | 
			
		||||
import (
 | 
			
		||||
	"fmt"
 | 
			
		||||
	"os"
 | 
			
		||||
	"path/filepath"
 | 
			
		||||
	"strings"
 | 
			
		||||
	"sync"
 | 
			
		||||
)
 | 
			
		||||
@@ -75,13 +74,6 @@ func concatenateError(err error, stderr string) error {
 | 
			
		||||
	return fmt.Errorf("%v - %s", err, stderr)
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
// If the object is stored in its own file (i.e not in a pack file),
 | 
			
		||||
// this function returns the full path to the object file.
 | 
			
		||||
// It does not test if the file exists.
 | 
			
		||||
func filepathFromSHA1(rootdir, sha1 string) string {
 | 
			
		||||
	return filepath.Join(rootdir, "objects", sha1[:2], sha1[2:])
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
// RefEndName return the end name of a ref name
 | 
			
		||||
func RefEndName(refStr string) string {
 | 
			
		||||
	if strings.HasPrefix(refStr, BranchPrefix) {
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user