Live data from Hacker News

The apt command: Combining apt-get and apt-cache and adds a progress bar (2014)

mvogt.wordpress.com

71–77 of 77 posts

Re: The apt command: Combining apt-get and apt-cache and adds a progress bar (2014)

#71

also don't forget apt-file (very useful to find out which package contains the library/binary you want to install) and dpkg -L to figure out what a particular package installed on your system. I switched to debian some time ago and it's interesting so many different commands are used for package management, this said I personally have an alias ap=sudo aptitude -t jessie-backports alias and use that as a command line…

Yes to apt-file, and 'apropos' seems to fit in there too (searches for keywords in package descriptions).

Re: The apt command: Combining apt-get and apt-cache and adds a progress bar (2014)

#72
post #61

Earlier quoted context omitted.

Debian's zigzagging between package management frontends (dselect, apt-*, aptitude, dpkg, now apt?, … all in use in parallel) is incredibly frustrating. Pacman e.g. is so much easier to use because everything's in one well-structured command.

Well, just use apt(8): apt install - Install packages apt remove - Remove packages apt upgrade - Upgrade packages without removing apt full-upgrade - Upgrade packages, allowing removals apt update - Refresh sources apt show - Show a package apt list - List packages, you can filter by stuff like --installed or --upgradable

1. "Just use $newtool" has been Debian's spiel for every past release, and every time it's a different one.

2. Why full-upgrade and not dist-upgrade like in all the other debian package managers? Would that little bit of internal consistency really have hurt?

3. Still does not seem to cover all use cases.

Re: The apt command: Combining apt-get and apt-cache and adds a progress bar (2014)

#73
post #8

I've never understood why debian insists on having these be different commands. It would make sense if install, search, upgrade and uninstall were all discrete, but the way it is today feels half implemented.

Only one of them requires readwrite system administrator privileges (eg sudo). apt-cache can be run by any user as it doesn't expose any secret data and can't be used to make changes. apt-get can install and uninstall software as well as download packages and thus needs root privileges in the classic UNIX model.

[deleted]

Re: The apt command: Combining apt-get and apt-cache and adds a progress bar (2014)

#74
post #14

Is this installed by default on Debian? If not, then this is a deal-breaker for me. I might as well install aptitude which also provides a similar command line interface.

It's provided by the same package as e.g. apt-get and apt-cache, so yes.

Thanks for the info, appreciate it!

Re: The apt command: Combining apt-get and apt-cache and adds a progress bar (2014)

#75
post #72

Earlier quoted context omitted.

Well, just use apt(8): apt install - Install packages apt remove - Remove packages apt upgrade - Upgrade packages without removing apt full-upgrade - Upgrade packages, allowing removals apt update - Refresh sources apt show - Show a package apt list - List packages, you can filter by stuff like --installed or --upgradable

1. "Just use $newtool" has been Debian's spiel for every past release, and every time it's a different one. 2. Why full-upgrade and not dist-upgrade like in all the other debian package managers? Would that little bit of internal consistency really have hurt? 3. Still does not seem to cover all use cases.

I don't know what you mean. dselect is like 2000 era, and was replaced by "aptitude" at least 15 years ago. "apt" has been around since the beginning and still works just fine. The fact that "aptitude" has some overlap with "apt" is a detail--its real strength is that its curses ui (which was a massive improvement over dselect).

Re: The apt command: Combining apt-get and apt-cache and adds a progress bar (2014)

#76

also don't forget apt-file (very useful to find out which package contains the library/binary you want to install) and dpkg -L to figure out what a particular package installed on your system. I switched to debian some time ago and it's interesting so many different commands are used for package management, this said I personally have an alias ap=sudo aptitude -t jessie-backports alias and use that as a command line…

Yes to apt-file, and 'apropos' seems to fit in there too (searches for keywords in package descriptions).

Replying because can't edit: "apt search $keyword" works like apropos but isn't in the tab completion on my Kubuntu 15.10.

Re: The apt command: Combining apt-get and apt-cache and adds a progress bar (2014)

#77
post #34

Earlier quoted context omitted.

I have this problem too. If I did myself shelling out to grep with pcre flags to find a simple library then there's a UX issue.

> If I find myself shelling out to grep with pcre flags, I am using unix pipes as intended Fixed that for you.

Hmm...except that I would guess search should do one thing well -- searching. Which, incidentally, using --name-only and/or regex, it does.
Post reply on HN