@@ -25,16 +25,14 @@ import (
2525 "github.com/pkg/errors"
2626)
2727
28- // ValidateLayout walks through the file tree given by src and
29- // validates the manifest pointed to by the given refs
30- // or returns an error if the validation failed.
28+ // ValidateLayout walks through the given file tree and validates the manifest
29+ // pointed to by the given refs or returns an error if the validation failed.
3130func ValidateLayout (src string , refs []string , out * log.Logger ) error {
3231 return validate (newPathWalker (src ), refs , out )
3332}
3433
35- // Validate walks through the given .tar file and
36- // validates the manifest pointed to by the given refs
37- // or returns an error if the validation failed.
34+ // Validate walks through the given .tar file and validates the manifest
35+ // pointed to by the given refs or returns an error if the validation failed.
3836func Validate (tarFile string , refs []string , out * log.Logger ) error {
3937 f , err := os .Open (tarFile )
4038 if err != nil {
@@ -96,18 +94,16 @@ func validate(w walker, refs []string, out *log.Logger) error {
9694 return nil
9795}
9896
99- // UnpackLayout walks through the file tree given by src and
100- // using the layers specified in the manifest pointed to by the given ref
101- // and unpacks all layers in the given destination directory
102- // or returns an error if the unpacking failed.
97+ // UnpackLayout walks through the file tree given by src and, using the layers
98+ // specified in the manifest pointed to by the given ref, unpacks all layers in
99+ // the given destination directory or returns an error if the unpacking failed.
103100func UnpackLayout (src , dest , ref string ) error {
104101 return unpack (newPathWalker (src ), dest , ref )
105102}
106103
107- // Unpack walks through the given .tar file and
108- // using the layers specified in the manifest pointed to by the given ref
109- // and unpacks all layers in the given destination directory
110- // or returns an error if the unpacking failed.
104+ // Unpack walks through the given .tar file and, using the layers specified in
105+ // the manifest pointed to by the given ref, unpacks all layers in the given
106+ // destination directory or returns an error if the unpacking failed.
111107func Unpack (tarFile , dest , ref string ) error {
112108 f , err := os .Open (tarFile )
113109 if err != nil {
0 commit comments