I have 20 or 30 deb files within a folder in a local directory, lets say /home/Downloads. Given that the amount of files may vary, I need a script(or command or whatever) which installs all these .deb when executed. I have no knowledge of scripting on Linux, so the most explicit the answers the better. Thanks in advance
Asked
Active
Viewed 512 times
1 Answers
1
I suggest using a for loop:
cd ~/Downloads
for i in *.deb; do echo installing "$i"; sudo dpkg -i "$i"; done;
for i in *.debloop into all "deb" filesecho installing "$i"print which one you are going to install- Using
dpkg -i packagewe install a "deb" package.
Hint: you can change dpkg -i with gdebi or apt install these options going to handle dependecies too (if any).
Ravexina
- 57,256