xbps icon indicating copy to clipboard operation
xbps copied to clipboard

Print install and remove messages below transaction summary

Open Chocimier opened this issue 4 years ago • 5 comments

Makes messages actually visible, and allow to delay update in case manual steps required after update are inconvenient at given time. As is, presence of messages breaks tools parsing xbps-install -n output, but I want that despite. There are no install messages in xbps or octoxbps dependency tree, so system update won't be affected.

~Pushed on top of static linking as publishing neither xbps_cb_message nor show_package_msgs used in xbps-install make sense.~

Also changed formatting a bit, now it looks like:

qt5ct-1.2_1 install x86_64 https://alpha.de.repo.voidlinux.org/current 825203 226027
git-lfs-2.12.1_1 install x86_64 https://alpha.de.repo.voidlinux.org/current 15180953 7175847
=== rustup-1.24.1_1: install message ===================================
Please run rustup-init after initial install to use rustup.
========================================================================
=== qt5ct-1.2_1: install message =======================================
To enable qt5ct restart the X11 server for the changes to take effect.
========================================================================
=== git-lfs-2.12.1_1: install message ==================================
Run 'git-lfs install' to configure git to use git-lfs
========================================================================

Chocimier avatar Jul 24 '21 15:07 Chocimier

Why? I feel something is done wrong if this needs a toggle.

You could have read them already and not want the spam, or to pipe the output through some filter/program (even if it's not advised), or something else I can't think of.

ericonr avatar Jul 30 '21 20:07 ericonr

And I don't see why keep the messages during installation. The most I'd do is print them after as a block reminder (but maybe only for the packages that succeeded, if a hook fails or something - assuming that's easy to implement).

ericonr avatar Jul 30 '21 20:07 ericonr

I'm not convinced about switch to disable. Config file don't fit, because you don't want to disable and forget. Flag don't fit, because existing tools won't use it, and adapted could use | sed -n '/^=/q; p' instead. What's left is env variable maybe.

You could have read them already and not want the spam

This is solved by showing message just once, administrators of multiple systems are encouraged to skim over anyway.

I don't see why keep the messages during installation.

removed

Mentioning packages list is added, but not really nice.

Chocimier avatar Aug 12 '21 17:08 Chocimier

Rebased, removed last line pointing to packages list and replaced static linking with exposing function, as agreed in other PR.

Chocimier avatar Sep 16 '23 14:09 Chocimier

I don't think breaking the -n output is good, what is the reason to print them there, would stderr be ok?

Duncaen avatar Sep 17 '23 15:09 Duncaen