2

The guide for installing Chrome on WSLg suggests to execute sudo apt install --fix-broken. I don't find the --fix-broken option documented in man apt. Is this option documented somewhere and/or what does it do?

2
  • You've not provided release details; but you can see the options with man apt-get as the apt reference manual doesn't still list everything.
    – guiverc
    May 26 at 7:17
  • 1
    It's worth clarifying for future readers that apt's definition of "broken" in this command does NOT mean "corrupt" or "incomplete" or "malfunctioning". In apt's view "broken" simply means a package version conflict. The logic of the package dependencies is broken. Example: Package A requires X>N, but Package B requires X<N.
    – user535733
    May 26 at 11:36

1 Answer 1

4

apt is a front-end/handler/alternative for apt-get as stated in man apt:

apt provides a high-level commandline interface for the package management system. It is
intended as an end user interface and enables some options better suited for interactive
usage by default compared to more specialized APT tools like apt-get(8) and apt-cache(8).

Which also has this stated as well:

Much like apt itself, its manpage is intended as an end user interface and as such only
mentions the most used commands and options partly to not duplicate information in
multiple places and partly to avoid overwhelming readers with a cornucopia of options and
details.

Therefore, man apt-get should be the resource for extended/specialized features ... And it has:

-f, --fix-broken
   Fix; attempt to correct a system with broken dependencies in place. This option, when
   used with install/remove, can omit any packages to permit APT to deduce a likely
   solution. If packages are specified, these have to completely correct the problem. The
   option is sometimes necessary when running APT for the first time; APT itself does not
   allow broken package dependencies to exist on a system. It is possible that a system's
   dependency structure can be so corrupt as to require manual intervention (which
   usually means using dpkg --remove to eliminate some of the offending packages). Use of
   this option together with -m may produce an error in some situations. Configuration
   Item: APT::Get::Fix-Broken.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.