Add support to mirror non package installer files

This commit is contained in:
Oliver Sauder
2017-11-23 14:22:41 +01:00
parent 9a704de43b
commit 108b0ea226
35 changed files with 593 additions and 153 deletions
+1 -2
View File
@@ -4,7 +4,6 @@ import (
"compress/bzip2"
"compress/gzip"
"context"
"fmt"
"io"
"net/url"
"os"
@@ -90,7 +89,7 @@ func DownloadTryCompression(ctx context.Context, downloader aptly.Downloader, ba
}
if err == nil {
err = fmt.Errorf("no candidates for %s found", baseURL.ResolveReference(&url.URL{Path: path}))
return nil, nil, &NoCandidateFoundError{URL: baseURL.ResolveReference(&url.URL{Path: path})}
}
return nil, nil, err
}