mirror of
https://github.com/aptly-dev/aptly.git
synced 2026-06-07 05:42:42 +00:00
Misc style and simple mistakes fixes.
This commit is contained in:
@@ -256,6 +256,12 @@ func CollectChangesFiles(locations []string, reporter aptly.ResultReporter) (cha
|
||||
|
||||
return nil
|
||||
})
|
||||
|
||||
if err != nil {
|
||||
reporter.Warning("Unable to process %s: %s", location, err2)
|
||||
failedFiles = append(failedFiles, location)
|
||||
continue
|
||||
}
|
||||
} else if strings.HasSuffix(info.Name(), ".changes") {
|
||||
changesFiles = append(changesFiles, location)
|
||||
}
|
||||
|
||||
+1
-1
@@ -127,7 +127,7 @@ func GetContentsFromDeb(packageFile string) ([]string, error) {
|
||||
case "data.tar.gz":
|
||||
ungzip, err := gzip.NewReader(library)
|
||||
if err != nil {
|
||||
return nil, fmt.Errorf("unable to ungzip data.tar.gz from %s: %s", packageFile,err)
|
||||
return nil, fmt.Errorf("unable to ungzip data.tar.gz from %s: %s", packageFile, err)
|
||||
}
|
||||
defer ungzip.Close()
|
||||
tarInput = ungzip
|
||||
|
||||
@@ -34,6 +34,12 @@ func CollectPackageFiles(locations []string, reporter aptly.ResultReporter) (pac
|
||||
|
||||
return nil
|
||||
})
|
||||
|
||||
if err2 != nil {
|
||||
reporter.Warning("Unable to process %s: %s", location, err2)
|
||||
failedFiles = append(failedFiles, location)
|
||||
continue
|
||||
}
|
||||
} else {
|
||||
if strings.HasSuffix(info.Name(), ".deb") || strings.HasSuffix(info.Name(), ".udeb") ||
|
||||
strings.HasSuffix(info.Name(), ".dsc") || strings.HasSuffix(info.Name(), ".ddeb") {
|
||||
|
||||
+1
-1
@@ -282,7 +282,7 @@ func depSliceDeduplicate(s []Dependency) []Dependency {
|
||||
|
||||
// VerifyDependencies looks for missing dependencies in package list.
|
||||
//
|
||||
// Analysis would be peformed for each architecture, in specified sources
|
||||
// Analysis would be performed for each architecture, in specified sources
|
||||
func (l *PackageList) VerifyDependencies(options int, architectures []string, sources *PackageList, progress aptly.Progress) ([]Dependency, error) {
|
||||
l.PrepareIndex()
|
||||
missing := make([]Dependency, 0, 128)
|
||||
|
||||
+1
-1
@@ -294,7 +294,7 @@ func (p *PublishedRepo) MarshalJSON() ([]byte, error) {
|
||||
})
|
||||
}
|
||||
|
||||
// String returns human-readable represenation of PublishedRepo
|
||||
// String returns human-readable representation of PublishedRepo
|
||||
func (p *PublishedRepo) String() string {
|
||||
var sources = []string{}
|
||||
|
||||
|
||||
+1
-1
@@ -146,7 +146,7 @@ func (repo *RemoteRepo) IsFlat() bool {
|
||||
return repo.Distribution == "" || (strings.HasPrefix(repo.Distribution, ".") && strings.HasSuffix(repo.Distribution, "/"))
|
||||
}
|
||||
|
||||
// NumPackages return number of packages retrived from remote repo
|
||||
// NumPackages return number of packages retrieved from remote repo
|
||||
func (repo *RemoteRepo) NumPackages() int {
|
||||
if repo.packageRefs == nil {
|
||||
return 0
|
||||
|
||||
Reference in New Issue
Block a user