Hacker News new | ask | show | jobs
by obtu 5253 days ago
My favourite feature is the search capabilities, which are well integrated and extremely powerful.

    # installed packages with yaml in the name
    aptitude search '~i yaml'

    # installed packages requiring yaml
    # (~D means depends on)
    aptitude search '~i ~D yaml'

    # packages whose name starts with lib and
    # mentioning SQL in their descriptions
    aptitude search '^lib ~d sql'

    # installed packages from some non-standard repo
    # apt-cache policy describes package origins
    aptitude search '~i ?origin(apt.opscode.com)'

    # why is libvirt0 installed?
    aptitude why libvirt0

    # which ubuntu metapackage is keeping libvirt0 installed?
    aptitude why '~i ubun' libvirt0 

    # don't keep any transitional package installed
    sudo aptitude markauto '~i ~d transitional'

    # purge ganeti packages
    sudo aptitude purge '~i ganeti'
1 comments

I didn't know about this matching. Awesome.

Now I'm even more annoyed that our servers are all CentOS :(