Communities

Writing
Writing
Codidact Meta
Codidact Meta
The Great Outdoors
The Great Outdoors
Photography & Video
Photography & Video
Scientific Speculation
Scientific Speculation
Cooking
Cooking
Electrical Engineering
Electrical Engineering
Judaism
Judaism
Languages & Linguistics
Languages & Linguistics
Software Development
Software Development
Mathematics
Mathematics
Christianity
Christianity
Code Golf
Code Golf
Music
Music
Physics
Physics
Linux Systems
Linux Systems
Power Users
Power Users
Tabletop RPGs
Tabletop RPGs
Community Proposals
Community Proposals
tag:snake search within a tag
answers:0 unanswered questions
user:xxxx search by author id
score:0.5 posts with 0.5+ score
"snake oil" exact phrase
votes:4 posts with 4+ votes
created:<1w created < 1 week ago
post_type:xxxx type of post
Search help
Notifications
Mark all as read See all your notifications »
Q&A

Post History

77%
+5 −0
Q&A Is this a robust way to distinguish explicitly installed packages from those pulled in as dependencies?

apt-mark aims to do this: the commands apt-mark showmanual and apt-mark showauto should show you respectively the packages which you explicitly installed and the ones which were added as dependenci...

posted 3y ago by Peter Taylor‭

Answer
#1: Initial revision by user avatar Peter Taylor‭ · 2021-05-22T17:15:40Z (almost 3 years ago)
`apt-mark` aims to do this: the commands `apt-mark showmanual` and `apt-mark showauto` should show you respectively the packages which you explicitly installed and the ones which were added as dependencies.

There are caveats.

1. There seems to be a common complaint that it shows too many packages as manual; it's possible that running `apt-mark minimize-manual` would address that complaint.
2. It's quite likely that some of the initially installed packages will be marked as manual, because `apt autoremove` will remove any package marked as auto which isn't a dependency of a package marked as manual. Running `apt-mark showmanual` at install and saving for future comparison would largely address this issue.