Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions copy_dir.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ package getter

import (
"context"
"errors"
"fmt"
"os"
"path/filepath"
Expand All @@ -24,6 +25,8 @@ func copyDir(ctx context.Context, dst string, src string, ignoreDot bool, disabl
// We can safely evaluate the symlinks here, even if disabled, because they
// will be checked before actual use in walkFn and copyFile
var err error
fmt.Println("copyDir - 27", src, dst)
return errors.New("copyDir is not implemented in this context")
resolved, err := filepath.EvalSymlinks(src)
if err != nil {
return err
Expand Down
5 changes: 4 additions & 1 deletion get_http.go
Original file line number Diff line number Diff line change
Expand Up @@ -169,6 +169,7 @@ func newLimitedWrappedReaderCloser(r io.ReadCloser, limit int64) io.ReadCloser {
}

func (g *HttpGetter) Get(dst string, u *url.URL) error {
fmt.Println("wwww again started the test")
ctx := g.Context()

// Optionally disable any X-Terraform-Get redirects. This is reccomended for usage of
Expand Down Expand Up @@ -296,6 +297,7 @@ func (g *HttpGetter) Get(dst string, u *url.URL) error {

// If there is a subdir component, then we download the root separately
// into a temporary directory, then copy over the proper subdir.
fmt.Println("wwwww reached before SourceDirSubdir check")
source, subDir := SourceDirSubdir(source)

var opts []ClientOption
Expand Down Expand Up @@ -362,9 +364,10 @@ func (g *HttpGetter) Get(dst string, u *url.URL) error {
// This is especially important to enforce a limit on X-Terraform-Get redirects
// which could be setup, if configured, at the top of this function.
opts = append(opts, WithContext(ctx))

fmt.Println("wwwww reached before subdir check")
if subDir != "" {
// We have a subdir, time to jump some hoops
fmt.Println("wwwww reached in subdir")
return g.getSubdir(ctx, dst, source, subDir, opts...)
}

Expand Down
1 change: 1 addition & 0 deletions get_http_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,7 @@ func TestHttpGetter_metaSubdir(t *testing.T) {
u.Path = "/meta-subdir"

// Get it!
fmt.Println("wwww started the test")
if err := g.Get(dst, &u); err != nil {
t.Fatalf("err: %s", err)
}
Expand Down
Loading