github.com/zhuohuang-hust/src-cbuild@v0.0.0-20230105071821-c7aab3e7c840/builder/context_windows.go (about)

     1  // +build windows
     2  
     3  package builder
     4  
     5  import (
     6  	"path/filepath"
     7  
     8  	"github.com/docker/docker/pkg/longpath"
     9  )
    10  
    11  func getContextRoot(srcPath string) (string, error) {
    12  	cr, err := filepath.Abs(srcPath)
    13  	if err != nil {
    14  		return "", err
    15  	}
    16  	return longpath.AddPrefix(cr), nil
    17  }