Skip to content

Commit

Permalink
[Queue] "Fix" for broken repository error on newer versions of APT (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
Diatrus authored Apr 15, 2021
1 parent 131429f commit f0b4bfc
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions Zebra/Queue/ZBQueue.m
Original file line number Diff line number Diff line change
Expand Up @@ -232,12 +232,8 @@ - (NSArray *)tasksToPerform {

if (ignoreDependencies || [[ZBDevice packageManagementBinary] isEqualToString:@"/usr/bin/dpkg"]) {
baseCommand = @[@"dpkg"];
}
else if ([[ZBDevice packageManagementBinary] isEqualToString:@"/usr/bin/apt"]) {
baseCommand = @[@"apt", @"-yqf", @"--allow-downgrades", @"--allow-change-held-packages", @"-oApt::Get::HideAutoRemove=true", @"-oquiet::NoProgress=true", @"-oquiet::NoStatistic=true", @"-oAPT::Sandbox::User=root", @"-oDir::State::lists="];
}
else {
baseCommand = @[@"apt", @"-yqf", @"--allow-downgrades", @"--allow-change-held-packages", @"-oApt::Get::HideAutoRemove=true", @"-oquiet::NoProgress=true", @"-oquiet::NoStatistic=true", @"-oAPT::Sandbox::User=root", @"-oDir::State::lists="];
} else {
baseCommand = @[@"apt", @"-yqf", @"--allow-downgrades", @"--allow-change-held-packages", @"-oApt::Get::HideAutoRemove=true", @"-oquiet::NoProgress=true", @"-oquiet::NoStatistic=true", @"-oAcquire::AllowUnsizedPackages=true", @"-oDir::State::lists="];
}

NSString *binary = baseCommand[0];
Expand Down

0 comments on commit f0b4bfc

Please sign in to comment.