You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

35 lines
1.1 KiB
Bash

#!/bin/sh
# check for things not installed via RPM and other junk
saubermann-common
echo "== should be installed via RPM or pip install --user:"
for site_packages in /usr/lib/python*/site-packages/; do
find $site_packages \( -name "*.egg-info" -or -name "*.dist-info" \) -exec rpm -qf {} \; 2>&1 | grep "not owned"
done
echo "== /usr/local"
find /usr/local/ -type f \
-and -not -name mimeinfo.cache \
-and -not -name defaults.list \
-print0 | xargs -0 rpm -qf 2>&1 | grep "not owned"
echo "== /usr/bin etc."
find /usr/bin /usr/sbin /usr/lib -type f \
\( \
-path '/usr/lib/modules/*/modules.*' -prune \
-or -path '*/__pycache__/*.py?' -prune \
-or -path '/usr/lib/fontconfig/cache/*' -prune \
-or -path '/usr/lib/jvm/*/*policy.jar' -prune \
-or -path '/usr/lib/modules/*/extra/*.ko' -prune \
-or -print0 \
\) | xargs -0 rpm -qf 2>&1 | grep "not owned"
echo "== *.rpmnew etc."
find /etc/ /usr/ \
-path '/usr/share/eclipse/dropins' -prune \
-or -name "*.rpm*" -and -not -name "*.rpm"
echo "== Orphan packages according to dnf"
dnf repoquery --extras