Hi,

There is a packages list file offered by every distro. The packages are list in this pattern in that txt file when opened in geany e.g

X-Arc-Collection 20200515-1
a52dec 0.7.4-11
aalib 1.4rc5-14
accountsservice 0.6.55-2
acl 2.2.53-3
adobe-source-code-pro-fonts 2.030ro+1.050it-6
adwaita-icon-theme 3.36.1-1
alsa-lib 1.2.3.1-1
alsa-plugins 1:1.2.2-2
alsa-topology-conf 1.2.3-1
alsa-ucm-conf 1.2.3-2
alsa-utils 1.2.3-2
aom 2.0.0-1
apr 1.7.0-3
apr-util 1.6.1-7
arch-install-scripts 23-2
archiso 44-2

How do I arrange all these files in one line on Geany or any other text editor without the packages versions numbers so I can install them at once with pacman ?

E.G

A one liner like this which I made manually but will become difficult to do manually if packages list has say 400 packages

# pacman -S X-Arc-Collection a52dec aalib accountsservice acl adobe-source-code-pro-fonts adwaita-icon-theme alsa-lib alsa-plugins alsa-topology-conf alsa-ucm-conf alsa-utils aom apr apr-util arch-install-scripts archiso

Can I get help about this whole thing please?

Regards,

archlinux-keyring 20200622-1
assuming the list in written at the $HOME/tmp/pkg_list file.
% res= ;while read line;do res+=( ${line%%' '*} );done <<< $(<$HOME/tmp/pkg_list);sudo pacman -S ${res}
Note on Arch X-Arc-Collection is an invalid package name.

Powered by Obarun