How to install a list of packages using apt-get?
If you have file (say pkglist
) which contains list of packages to be installed like:
pkg1
pkg2
pkg3
or
pkg1 pkg2 pkg3
Then you can install that packages by apt
using following command:
sudo apt-get install $(cat pkglist)
xargs sudo apt-get install < pkglist
For more infromation on apt-get install
visit man apt-get
install section.
Yep, just list all packages in a line separated by a space. e.g.
sudo apt-get install package_name1 package_name2 package_name3 package_name4