Skip to content

[FEAT] Differentiate emerge package counts by set (@world, @system, deps) #2230

@hydrospherics

Description

@hydrospherics

Description

General inquiry and asking for guidance on implementing set differentiation for Portage sets.

Motivation

Currently, fastfetch reports all emerge packages as a single count, conflating @world, @system, and pulled-in dependencies. Poor Portage getting discriminated while nixpkgs gets first-class treatment..

As per the Gentoo Wiki on Package Sets, @system and @profile are "defined by the Gentoo development team" as the base set of packages required for the OS to function, so essentially system-level metadata.

Since fastfetch already differentiates nix-system and nix-user, Portage deserves the same parity. Calculating these essentially costs nothing, it's just reading /var/lib/portage/world and the profile's packages file.

Counts would be mutually exclusive: total - (@world + @system) = deps. Two formats on the table:

1:

packages: 76 (@world), 50 (@system), 919 (emerge-deps), 12 (flatpak)

2 (much like nix-system/nix-user):

packages: 76 (emerge-world), 50 (emerge-system), 919 (emerge-deps), 12 (flatpak)

or whichever you guys prefer, I'll try and see.

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions