The officially official Devuan Forum!

You are not logged in.

#1 Yesterday 15:27:20

igorzwx
Member
Registered: 2024-05-06
Posts: 271  

apt seems to be a sort of "unstable wrapper"

apt is said to be designed as a more interactive and user-friendly frontend to certain utilities such as apt-get, apt-cache, etc.

$ apt-file list apt | grep usr/bin
apt: /usr/bin/apt
apt: /usr/bin/apt-cache
apt: /usr/bin/apt-cdrom
apt: /usr/bin/apt-config
apt: /usr/bin/apt-get
apt: /usr/bin/apt-key
apt: /usr/bin/apt-mark 

apt is optimized for interactive use, with user-friendly output and features.
   In contrast, apt-get has a well-defined, stable interface, making it more suitable for scripting and automated tasks.

   apt is essentially a wrapper for the most common functionalities found in the underlying APT system.

Last edited by igorzwx (Yesterday 15:27:54)

Offline

#2 Yesterday 15:32:12

rolfie
Member
Registered: 2017-11-25
Posts: 1,295  

Re: apt seems to be a sort of "unstable wrapper"

apt has a progress bar. Perfect for me, I am using apt since many years now, no complaints about it.

Offline

#3 Yesterday 16:00:35

igorzwx
Member
Registered: 2024-05-06
Posts: 271  

Re: apt seems to be a sort of "unstable wrapper"

If you know what it really is, you can decide how to use it.
However, the users are not supposed to know what they are using.

Offline

#4 Yesterday 16:46:34

rolfie
Member
Registered: 2017-11-25
Posts: 1,295  

Re: apt seems to be a sort of "unstable wrapper"

Why not? If you desire have a look at the code. The sources are available.

Offline

#5 Yesterday 17:19:03

pcalvert
Member
Registered: 2017-05-15
Posts: 245  

Re: apt seems to be a sort of "unstable wrapper"

The only apt command I use is apt update. For almost everything else I use aptitude.


Freespoke is a new search engine that respects user privacy and does not engage in censorship.
Another one is called Luxxle.

Offline

#6 Yesterday 18:19:33

igorzwx
Member
Registered: 2024-05-06
Posts: 271  

Re: apt seems to be a sort of "unstable wrapper"

@rolfie

Could you please read the code and enlighten us?

Offline

#7 Yesterday 19:00:19

rolfie
Member
Registered: 2017-11-25
Posts: 1,295  

Re: apt seems to be a sort of "unstable wrapper"

Another conspiracy theory about something being bad?

igorzwx wrote:

Could you please read the code and enlighten us?

I am no programmer. Do it yourself.

Offline

#8 Yesterday 19:34:25

igorzwx
Member
Registered: 2024-05-06
Posts: 271  

Re: apt seems to be a sort of "unstable wrapper"

apt has undocumented options, for example: depends; build-dep; -s, --simulate

man apt | grep depends
$ apt depends wxmaxima
wxmaxima
  Depends: libc6 (>= 2.34)
  Depends: libgcc-s1 (>= 3.3.1)
  Depends: libstdc++6 (>= 11)
  Depends: libwxbase3.2-1 (>= 3.2.2+dfsg)
  Depends: libwxgtk-webview3.2-1 (>= 3.2.2+dfsg)
  Depends: libwxgtk3.2-1 (>= 3.2.1+dfsg-2)
  Recommends: maxima
    maxima-git
  Recommends: fonts-inter
  Recommends: fonts-inter-variable
  Recommends: fonts-texgyre
  Recommends: fonts-texgyre-math
  Recommends: fonts-dejavu
  Suggests: fonts-jsmath
  Suggests: texlive-latex-extra
  Suggests: ibus-gtk3
man apt | grep build-dep
$ apt build-dep wxmaxima -s
NOTE: This is only a simulation!
      apt needs root privileges for real execution.
      Keep also in mind that locking is deactivated,
      so don't depend on the relevance to the real current situation!
Reading package lists... Done
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
...

There are, perhaps, other "secret" options.

Last edited by igorzwx (Yesterday 21:02:54)

Offline

#9 Yesterday 21:07:51

EDX-0
Member
Registered: 2020-12-12
Posts: 146  

Re: apt seems to be a sort of "unstable wrapper"

apt is a "work in progress" interactive tool, it has undocumented options (if you don't read the manual) since they may not be tested enough to have full documentation, for example for apt 2.9.6devuan1

       edit-sources (work-in-progress)
           edit-sources lets you edit your sources.list(5) files in your preferred text editor
           while also providing basic sanity checks.

       showsrc, depends, rdepends, policy (summarised in apt-cache(8))

       source, build-dep, download, changelog, clean, distclean, autoclean (summarised in apt-
       get(8))

SCRIPT USAGE AND DIFFERENCES FROM OTHER APT TOOLS
       The apt(8) commandline is designed as an end-user tool and it may change behavior between
       versions. While it tries not to break backward compatibility this is not guaranteed either
       if a change seems beneficial for interactive use.

       All features of apt(8) are available in dedicated APT tools like apt-get(8) and apt-cache(8)
       as well.  apt(8) just changes the default value of some options (see apt.conf(5) and
       specifically the Binary scope). So you should prefer using these commands (potentially with
       some additional options enabled) in your scripts as they keep backward compatibility as much
       as possible.

SEE ALSO
       apt-get(8), apt-cache(8), sources.list(5), apt.conf(5), apt-config(8), apt-patterns(7), The
       APT User's guide in /usr/share/doc/apt-doc/, apt_preferences(5), the APT Howto.

Offline

#10 Yesterday 21:30:26

igorzwx
Member
Registered: 2024-05-06
Posts: 271  

Re: apt seems to be a sort of "unstable wrapper"

I have Devuan5

$ inxi -b | grep Host -A1
  Host: devuan Kernel: 6.1.0-39-amd64 arch: x86_64 bits: 64 Desktop: MATE
    v: 1.26.0 Distro: Devuan GNU/Linux 5 (daedalus)
$ man apt | grep devuan1
APT 2.6.1devuan1         05 April 2020             APT(8)

It seems that "man" is "outdated in-progress".

$ apt --version
apt 2.6.1devuan1 (amd64)
man apt | grep depends

does not print anythings.

$ apt rdepends wxmaxima
wxmaxima
Reverse Depends:
  Suggests: education-mathematics
  Recommends: science-mathematics

The command:

man apt | grep rdepends

prints nothing.

apt is "work in progress", and, therefore,

apt full-upgrade

is recommended to use instead of

apt-get dist-upgrade

_https://www.debian.org/releases/trixie/release-notes/upgrading.html#upgrading-the-system

4.4.6. Upgrading the system

# apt full-upgrade

Linux Mint has own apt wrapper

_https://github.com/linuxmint/mintsystem/blob/master/usr/local/bin/apt

This is the Linux Mint "apt" command.

This commands acts as a wrapper for the APT package manager and many other useful tools such as apt-get, apt-cache, apt-mark, dpkg, aptitude...etc.

It is installed in /usr/local/bin/apt. To use the upstream apt command directly type /usr/bin/apt.

Last edited by igorzwx (Today 00:16:36)

Offline

#11 Today 02:53:23

EDX-0
Member
Registered: 2020-12-12
Posts: 146  

Re: apt seems to be a sort of "unstable wrapper"

yes, i've been thinking of rolling out my own apt wrapper, after all i already have apt-ui which uses fzf to provide a fuzzy ui for installing, uninstalling packages and also queriying package information: https://github.com/eylles/devuan-script … /apt-ui.sh

but i do want something more "complete" that also integrates some of the apt-fast capabilities which i may even lazy out and just build my apt wrapper with the ability to use apt-fast to perform the install operations.

that is not to say that debian's "apt" wrapper program is bad in on itself but one can notice it is very much a work in progress

Offline

Board footer