Commit Graph

25 Commits (1dc70477b5e9b07808001093ec33d2530d1799e1)

Author SHA1 Message Date
Timo Teräs 1dc70477b5 solver: fix installation of non-repository packages during tmpfs boot
allow packages in the cache's installed to be selected for installation
by the solver. add test case for the issue.
2014-05-19 11:50:10 +03:00
Natanael Copa 0a4ff4f534 commit: fix segfault
apk would try run the trigger even if package failed to install.
2013-08-05 10:57:00 +02:00
Timo Teräs 065427f417 commit: don't ask questions if simulating 2013-08-03 17:31:49 +03:00
Timo Teräs f28e77b64d commit: fix another re-installing misspelling to reinstalling 2013-06-21 11:32:23 +03:00
Timo Teräs e1068ce649 commit: fix ssize_t printing 2013-06-20 15:56:04 +03:00
Timo Teräs 7e18398781 commit, db: make file conflicts and script errors non-fatal
fixes #1482
2013-06-20 13:12:44 +03:00
Timo Teräs 17145f82ae solver: fix package deletion to consier provides properly 2013-06-19 21:39:01 +03:00
Timo Teräs 6da083fc24 all: few behavioural regression fixes
Wildcard matching with no names should match all packages only for
info and search applet. "apk del" would otherwise try to delete
everything, etc.

Fix also interactive mode to ask questions only if we are actually
changing something.
2013-06-19 20:56:18 +03:00
Natanael Copa adc5b0b161 print: move progress bar update logic to apk_print_progress
- let the apk_print functions deal with the forced print itself. We
  avoid that the callbacks need to deal with the force flag. We can
  also get rid of the APK_PRINT_PROGRESS_* defines.

- let the reader of --progress-fd decide how often things are updated
  rather than having a fixed granularity off 1/100 (percent)

- avoid detect screen size and percent/bar calculations in case the
  --no-progress was given

- track satistics for both the ascii bar and percent info and update bar
  only if either percent or bar changes. This makes the bar go smoother
  when width is wider than 100 chars and it makes the percent counter
  go smooth when screen width is less thann 100 chars. It also
  simplifies the callbacks as they no longer need to deal with update
  granularity.
2013-06-19 10:00:31 +00:00
Timo Teräs d315c9019c upgrade: new option: --latest (-l)
Select latest version of package (if it is not pinned), and print
error if it cannot be installed due to other dependencies.

Together with --available, it selects the latest package which is
present at least in some repository.

This also fixes few solver issues with ordering of package selection
that got quite apparent with this flag. Namely, we cannot "lock"
a package until it's reverse dependencies are locked or not all of
the solver flags are propagated properly.
2013-06-19 08:33:51 +03:00
Timo Teräs f91b01fea8 errors: fix a test case, and misanalysis of certain names
the pinning11 changed when @repo got the leading @ on error messages.
analyze_dep() now properly ignores conflict dependencies, as those
names are usually intentionally left unassigned.
2013-06-18 16:23:14 +03:00
Timo Teräs 98c6b46de6 db: store repository tag names including leading @ 2013-06-18 14:30:44 +03:00
Timo Teräs 01ec60f718 errors: improve analysis for virtual packages
if all packages named N provide the virtual package, list only the
name N instead of all packages providing it.
2013-06-18 08:03:40 +03:00
Timo Teräs 54509e7a1a all: various conversions to foreach_array_item, and simplifications of code 2013-06-18 08:03:40 +03:00
Timo Teräs 656190b0a0 io: get rid of APK_PROGRESS_SCALE
no need to muldiv all the time, just pass the current amount of bytes
done, and let callbacks use that directly.
2013-06-17 17:28:03 +03:00
Timo Teräs ade8d0b4e9 cache: implement progress bar (ref #1170) 2013-06-17 17:13:14 +03:00
Timo Teräs 0a13141889 print: move progress printing to common functions 2013-06-17 16:47:49 +03:00
Timo Teräs ac0c7457c2 errors: detect self-conflicts properly
and add the provided version information to the conflicts.
fixes the final test case that was broken. hooray.
2013-06-14 21:37:38 +03:00
Timo Teräs 59d15ab259 solver, errors: fix few additional test cases and clean ups 2013-06-13 21:59:08 +03:00
Timo Teräs bcda66bf08 pkg: add global reverse dependency iterator helpers and use them
... in the error printing and the package deletion.
2013-06-13 20:48:38 +03:00
Timo Teräs e51232e710 errors: rewrite the logic how errors are reported
Instead of the dependency oriented logic, switch to print them
for each package or name needed. Might give a bit more readable
errors now. There's still few corner cases that proper error is
not output, which are cought by the test cases.
2013-06-13 18:22:00 +03:00
Timo Teräs 25ff68a87e solver: prune broken world dependencies with --force
mostly useful for reboot, when all packages are not available.
2013-06-13 18:22:00 +03:00
Timo Teräs e7fd4d03bf solver: rewrite as deductive solver -- pinning support
Fix also pinning test cases to be more sane.
2013-06-13 18:22:00 +03:00
Timo Teräs 426a12686e solver: rewrite as deductive solver -- per name flags
Handle properly per-name preference flags, and add test cases
for testing those via fix applet.
2013-06-13 18:22:00 +03:00
Timo Teräs b8c44536ca solver: rewrite as deductive solver -- core features
Implementing basic dependency handling, install_if and awareness
of pinning.
2013-06-13 18:22:00 +03:00