mirror of
https://github.com/aptly-dev/aptly.git
synced 2026-06-04 05:10:40 +00:00
Show progress when loading packages from reflist.
This commit is contained in:
+1
-1
@@ -37,7 +37,7 @@ func aptlyRepoAdd(cmd *commander.Command, args []string) error {
|
||||
context.progress.Printf("Loading packages...\n")
|
||||
|
||||
packageCollection := debian.NewPackageCollection(context.database)
|
||||
list, err := debian.NewPackageListFromRefList(repo.RefList(), packageCollection)
|
||||
list, err := debian.NewPackageListFromRefList(repo.RefList(), packageCollection, context.progress)
|
||||
if err != nil {
|
||||
return fmt.Errorf("unable to load packages: %s", err)
|
||||
}
|
||||
|
||||
+2
-2
@@ -75,12 +75,12 @@ func aptlyRepoMoveCopyImport(cmd *commander.Command, args []string) error {
|
||||
context.progress.Printf("Loading packages...\n")
|
||||
|
||||
packageCollection := debian.NewPackageCollection(context.database)
|
||||
dstList, err := debian.NewPackageListFromRefList(dstRepo.RefList(), packageCollection)
|
||||
dstList, err := debian.NewPackageListFromRefList(dstRepo.RefList(), packageCollection, context.progress)
|
||||
if err != nil {
|
||||
return fmt.Errorf("unable to load packages: %s", err)
|
||||
}
|
||||
|
||||
srcList, err := debian.NewPackageListFromRefList(srcRefList, packageCollection)
|
||||
srcList, err := debian.NewPackageListFromRefList(srcRefList, packageCollection, context.progress)
|
||||
if err != nil {
|
||||
return fmt.Errorf("unable to load packages: %s", err)
|
||||
}
|
||||
|
||||
+1
-1
@@ -30,7 +30,7 @@ func aptlyRepoRemove(cmd *commander.Command, args []string) error {
|
||||
context.progress.Printf("Loading packages...\n")
|
||||
|
||||
packageCollection := debian.NewPackageCollection(context.database)
|
||||
list, err := debian.NewPackageListFromRefList(repo.RefList(), packageCollection)
|
||||
list, err := debian.NewPackageListFromRefList(repo.RefList(), packageCollection, context.progress)
|
||||
if err != nil {
|
||||
return fmt.Errorf("unable to load packages: %s", err)
|
||||
}
|
||||
|
||||
@@ -49,12 +49,12 @@ func aptlySnapshotPull(cmd *commander.Command, args []string) error {
|
||||
|
||||
// Convert snapshot to package list
|
||||
context.progress.Printf("Loading packages (%d)...\n", snapshot.RefList().Len()+source.RefList().Len())
|
||||
packageList, err := debian.NewPackageListFromRefList(snapshot.RefList(), packageCollection)
|
||||
packageList, err := debian.NewPackageListFromRefList(snapshot.RefList(), packageCollection, context.progress)
|
||||
if err != nil {
|
||||
return fmt.Errorf("unable to load packages: %s", err)
|
||||
}
|
||||
|
||||
sourcePackageList, err := debian.NewPackageListFromRefList(source.RefList(), packageCollection)
|
||||
sourcePackageList, err := debian.NewPackageListFromRefList(source.RefList(), packageCollection, context.progress)
|
||||
if err != nil {
|
||||
return fmt.Errorf("unable to load packages: %s", err)
|
||||
}
|
||||
|
||||
@@ -31,7 +31,9 @@ func aptlySnapshotVerify(cmd *commander.Command, args []string) error {
|
||||
}
|
||||
}
|
||||
|
||||
packageList, err := debian.NewPackageListFromRefList(snapshots[0].RefList(), packageCollection)
|
||||
context.progress.Printf("Loading packages...\n")
|
||||
|
||||
packageList, err := debian.NewPackageListFromRefList(snapshots[0].RefList(), packageCollection, context.progress)
|
||||
if err != nil {
|
||||
fmt.Errorf("unable to load packages: %s", err)
|
||||
}
|
||||
@@ -43,7 +45,7 @@ func aptlySnapshotVerify(cmd *commander.Command, args []string) error {
|
||||
}
|
||||
|
||||
for i := 1; i < len(snapshots); i++ {
|
||||
pL, err := debian.NewPackageListFromRefList(snapshots[i].RefList(), packageCollection)
|
||||
pL, err := debian.NewPackageListFromRefList(snapshots[i].RefList(), packageCollection, context.progress)
|
||||
if err != nil {
|
||||
fmt.Errorf("unable to load packages: %s", err)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user