Ncontrol Deb -

sudo dpkg --purge package-name sudo apt update sudo apt install package-name # from official repo To a manually installed package into a controlled local repo, use dpkg-repack :

cat <<EOF | sudo tee /etc/apt/preferences.d/pin-uncontrolled Package: your-package-name Pin: version * Pin-Priority: 1001 EOF This prevents APT from replacing your manual package during upgrades. If you must install an uncontrolled deb that has missing dependencies, you can force it: ncontrol deb

sudo mkdir -p /usr/local/debs sudo mv ~/your-package.deb /usr/local/debs/ sudo dpkg-scanpackages /usr/local/debs /dev/null | sudo tee /usr/local/debs/Packages echo "deb [trusted=yes] file:///usr/local/debs ./" | sudo tee /etc/apt/sources.list.d/local.list sudo apt update sudo apt install your-package # Now controlled! Now APT tracks dependencies and updates. If you cannot create a local repo, at least pin the package to prevent automatic removal: sudo dpkg --purge package-name sudo apt update sudo

apt list --installed | grep -v "now" Or more precisely: If you cannot create a local repo, at

In the polished world of Debian-based Linux systems (Ubuntu, Debian, Mint, etc.), we take comfort in apt — the package manager that resolves dependencies, tracks versions, and keeps everything in harmony. But beneath the surface lies a wild west: the package. These are packages installed manually, bypassing the repository and dependency tracking systems.

apt-mark showmanual | grep -vFf <(apt-mark showauto) But for true "no repository origin" detection:

sudo dpkg --force-depends -i broken-package.deb Then manually install missing deps with apt . This is dangerous — use only as a last resort. For end-user applications, the best "uncontrolled deb" alternative is to avoid .deb entirely:

sudo dpkg --purge package-name sudo apt update sudo apt install package-name # from official repo To a manually installed package into a controlled local repo, use dpkg-repack :

cat <<EOF | sudo tee /etc/apt/preferences.d/pin-uncontrolled Package: your-package-name Pin: version * Pin-Priority: 1001 EOF This prevents APT from replacing your manual package during upgrades. If you must install an uncontrolled deb that has missing dependencies, you can force it:

sudo mkdir -p /usr/local/debs sudo mv ~/your-package.deb /usr/local/debs/ sudo dpkg-scanpackages /usr/local/debs /dev/null | sudo tee /usr/local/debs/Packages echo "deb [trusted=yes] file:///usr/local/debs ./" | sudo tee /etc/apt/sources.list.d/local.list sudo apt update sudo apt install your-package # Now controlled! Now APT tracks dependencies and updates. If you cannot create a local repo, at least pin the package to prevent automatic removal:

apt list --installed | grep -v "now" Or more precisely:

In the polished world of Debian-based Linux systems (Ubuntu, Debian, Mint, etc.), we take comfort in apt — the package manager that resolves dependencies, tracks versions, and keeps everything in harmony. But beneath the surface lies a wild west: the package. These are packages installed manually, bypassing the repository and dependency tracking systems.

apt-mark showmanual | grep -vFf <(apt-mark showauto) But for true "no repository origin" detection:

sudo dpkg --force-depends -i broken-package.deb Then manually install missing deps with apt . This is dangerous — use only as a last resort. For end-user applications, the best "uncontrolled deb" alternative is to avoid .deb entirely: