indeb - Bash script to install .deb packages

Endrit Qerreti

Endrit Qerreti

Installing .deb packages on linux is easy, however sometimes it can be time consuming when installing them via the terminal, especially when you have a lot of files to go through to find the .deb file that you want to install.

Indeb(Install .deb), is a simple bash script that I wrote that installs the .deb package automatically without having to type anything on terminal, all you have to do is run ./ and then set the package name and press enter, this can be a filename.deb or the directory where the .deb file is located, example : /home/owlhowto/downloads/myfil.deb

How does work?

1) You run the bash script ./

2) Indeb lists all .deb files located under the directory from where you launched, to make it easier to copy and paste the file name that you want to install. Assuming the downloads folder is default folder where you download stuff, then you can execute on the same location.

3) You enter the .deb filename and press enter

4) Indeb installs it on your system


#Indeb - Install .deb packages on debian based system
#Written by : Endrit Qerreti
#Version : 1.0
#Copyright (c) 2023 Endrit Qerreti

blue=$(tput setaf 4)
red=$(tput setaf 1)
white=$(tput setaf 7)
yellow=$(tput setaf 3)
reset=$(tput sgr0)

cat <<EOF


Install .deb packages on debian based system

lsdeb=$(ls *.deb 2>/dev/null) 

if [[ -z "$lsdeb" ]];

echo -e "\n${red}no deb file was found${reset}" 
echo -e "\n${white}add the deb file and start indeb again${reset}\n"


echo -e "${yellow}\nDeb files found: \n $lsdeb ${reset}\n" 

read -p "Enter ${blue}.deb${blue}${reset} package name and press enter:  " deb

if [[ $deb == *.deb* ]];

echo -e "\n$deb Selected\n"

echo -e "\n${white}Installing${white} ${yellow} $deb${yellow} ...${reset}\n"

install_deb=$(sudo dpkg -i $deb)
echo -e "\nInstallation completed\n"
echo -e "\n${red}[x]This is not a .deb file${reset}\n"
exit 1

echo -e "\n${red}[x]This is not a .deb file${reset}\n"
exit 1


How to use

Step 1 - Make executable

Run the command below to make executable

chmod +x

Step 2 - Run

Next, run the script


Note: Since the script will check for the deb files located on the same directory from where you are running indeb, then I'd suggest you run indeb from the download folder.

Once you run indeb, the app will list the deb files found on the same folder, you can copy and paste the name of the file that is being showed on the terminal and press enter, then indeb will install that package.

If the package is not a valid .deb file, the app will exit and you will need to run it again in order to install it.  For example, in the folder that I ran indeb I had only virtualbox-7.0_7.0.8-156879Debianbullseye_amd64.deb

You can also set the direct path of the deb file instead of the package name. The direct path looks like this


And press enter to start the installation process

On this step, you will need to enter your sudo password in order to be able to install the selected .deb package. To avoid this, you can run as sudo and then the app will not ask you to authenticate again.

sudo ./


indeb is a simple bash script that installs the .deb packages on debian based linux distros.