• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
  • Skip to footer navigation

The Geek Diary

  • OS
    • Linux
    • CentOS/RHEL
    • VCS
  • Interview Questions
  • Database
    • MariaDB
  • DevOps
    • Docker
    • Shell Scripting
  • Big Data
    • Hadoop
    • Cloudera
    • Hortonworks HDP

pactree Command Examples in Linux

by Deepika

“pactree” is a tool in Arch Linux that allows users to view the dependencies of packages installed on their system. The tool displays the dependencies of a package in the form of a tree, showing the parent package and all the packages that it depends on. This provides a visual representation of the relationships between packages, making it easier to understand the dependencies of a package and to see what packages are needed in order to install a particular package.

“pactree” can be used to list the dependencies of a single package, or to display the complete dependency tree of all installed packages. This information can be useful for troubleshooting problems with the system, for example, if a package is missing a required dependency, or if a package is causing a conflict with another package. “pactree” can also be used to evaluate the impact of installing or removing a package, by showing the packages that would be affected.

pactree Command Examples

1. Print the dependency tree of a specific package:

# pactree package

2. Print what packages depend on a specific package:

# pactree --reverse package

3. Dump dependencies one per line, skipping duplicates:

# pactree --unique package

4. Include optional dependencies of a specific package and colorize the output:

# pactree --optional --color package

5. Display help:

# pactree

Filed Under: Linux

Some more articles you might also be interested in …

  1. gpgv Command Examples
  2. jwt Command Examples
  3. zip: command not found
  4. foreman Command Examples in Linux
  5. nmcli device Command Examples in Linux
  6. gobuster Command Examples
  7. wajig: command not found
  8. CentOS / RHEL 6 : How to add/remove additional IP addresses to a network interface
  9. git annotate: Show commit hash and last author on each line of a file
  10. gnome-extension Command Examples in Linux

You May Also Like

Primary Sidebar

Recent Posts

  • Vanilla OS 2 Released: A New Era for Linux Enthusiasts
  • mk Command Examples
  • mixxx Command Examples
  • mix Command Examples

© 2025 · The Geek Diary

  • Archives
  • Contact Us
  • Copyright