diff --git a/pkg/fs/confirmeddir.go b/pkg/fs/confirmeddir.go index 9774bb846..a07335a89 100644 --- a/pkg/fs/confirmeddir.go +++ b/pkg/fs/confirmeddir.go @@ -1,3 +1,19 @@ +/* +Copyright 2018 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + package fs import ( @@ -32,11 +48,10 @@ type ConfirmedDir string // actual path existence. // // This is tested on linux, but will have trouble -// on other operating systems. As soon as related -// work is completed in the core filepath package, -// this code should be refactored to use it. -// See: -// https://github.com/golang/go/issues/18355 +// on other operating systems. +// TODO(monopole) Refactor when #golang/go/18358 closes. +// See also: +// https://github.com/golang/go/issues/18358 // https://github.com/golang/dep/issues/296 // https://github.com/golang/dep/blob/master/internal/fs/fs.go#L33 // https://codereview.appspot.com/5712045 diff --git a/pkg/fs/confirmeddir_test.go b/pkg/fs/confirmeddir_test.go index 1f097b14e..eddc2a198 100644 --- a/pkg/fs/confirmeddir_test.go +++ b/pkg/fs/confirmeddir_test.go @@ -1,3 +1,19 @@ +/* +Copyright 2018 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + package fs import ( diff --git a/pkg/loader/fileloader.go b/pkg/loader/fileloader.go index 02864582c..1d4e1e98b 100644 --- a/pkg/loader/fileloader.go +++ b/pkg/loader/fileloader.go @@ -216,6 +216,10 @@ func (l *fileLoader) errIfArgEqualOrHigher( return l.referrer.errIfArgEqualOrHigher(candidateRoot) } +// TODO(monopole): Distinguish branches? +// I.e. Allow a distinction between git URI with +// path foo and tag bar and a git URI with the same +// path but a different tag? func (l *fileLoader) errIfPreviouslySeenUri(uri string) error { if strings.HasPrefix(l.uri, uri) { return fmt.Errorf(