mirror of
https://github.com/k3s-io/k3s.git
synced 2024-06-07 19:41:36 +00:00
14 lines
248 B
Go
14 lines
248 B
Go
package wclayer
|
|
|
|
import (
|
|
"path/filepath"
|
|
|
|
"github.com/Microsoft/go-winio/pkg/guid"
|
|
)
|
|
|
|
// LayerID returns the layer ID of a layer on disk.
|
|
func LayerID(path string) (guid.GUID, error) {
|
|
_, file := filepath.Split(path)
|
|
return NameToGuid(file)
|
|
}
|