Slight off-topic, but I wanted to address the above concern.
APT, DNF, and many other package managers have an "autoremove" command that will uninstall unused dependencies. So if you did "apt-get -y install $PACKAGE && apt-get -y remove $PACKAGE && apt-get autoremove", you won't have any of $PACKAGE's dependencies hanging around after.