Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

improve hierarchy display of snapshots #648

Open
lnussel opened this issue May 5, 2021 · 1 comment
Open

improve hierarchy display of snapshots #648

lnussel opened this issue May 5, 2021 · 1 comment

Comments

@lnussel
Copy link
Member

lnussel commented May 5, 2021

The default list display of snapper does not state the "parent" of a snapshot. So after a rollback it's not clear which snapshots are based on common history. The "pre" column is only used snapshots of type "post"

Example of a normal system:

    # | Type   | Pre # | Date                     | User | Used Space | Cleanup | Description  | Userdata     
------+--------+-------+--------------------------+------+------------+---------+--------------+--------------
   0  | single |       |                          | root |            |         | current      |              
 865* | single |       | Mon Dec 16 13:51:18 2019 | root | 203.57 MiB |         |              |              
 956  | pre    |       | Tue Aug  4 13:07:58 2020 | root | 628.38 MiB | number  | zypp(zypper) | important=yes
 957  | post   |   956 | Tue Aug  4 13:09:24 2020 | root | 326.64 MiB | number  |              | important=yes

On a transactional system the "pre" column is always empty and using space without need:

# snapper list
   # | Type   | Pre # | Date                     | User | Used Space | Cleanup | Description             | Userdata     
-----+--------+-------+--------------------------+------+------------+---------+-------------------------+--------------
  0  | single |       |                          | root |            |         | current                 |              
301  | single |       | Tue May  4 13:06:56 2021 | root |  44.82 MiB | number  | Snapshot Update of #300 | important=yes
302  | single |       | Tue May  4 15:38:48 2021 | root |   6.27 MiB | number  | Snapshot Update of #301 | important=yes
303* | single |       | Tue May  4 15:52:45 2021 | root |  17.75 MiB | number  | Snapshot Update of #302 | important=yes

As a workaround for missing history information the description is abused to contain the parent snapshot.

Maybe the list display could be improved to be able to express the history without the description?
Maybe a different style needs to be used for normal vs transactional systems?

@aschnell
Copy link
Member

aschnell commented May 5, 2021

It is already possible to change the columns using the --columns parameter.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants