0

Is there any way to install all packages shown by pressing tab? For example, I want to install all octave available packages. When I type # aptitude install octave and press TAB a list of packages that its name start by octave is shown.

aptitude install octave
octave                        octave-mpi
octave-bim                    octave-msh
octave-biosig                 octave-nan
octave-common                 octave-nlopt
octave-communications         octave-nurbs
octave-communications-common
--More--

How to install all of them?

I tried with # aptitude install octave* but it doesn't works.

  • Do you really need them all? Usually you install octave and aptitude installs all the dependencies needed. – derHugo Nov 5 '17 at 22:46
  • I know that. What i really need is the command for install all of them. I want to install, for example, xfce full desktop environment. – Gabriel Sandoval Nov 5 '17 at 22:50
  • Well this case would be sudo aptitude install xubuntu-desktop ;) but I got your question .. I'm just surprised * does not work.. – derHugo Nov 5 '17 at 22:51
  • What happens instead? Probably you run into concurrent packages or dependencies which cannot exist the Same time.. – derHugo Nov 5 '17 at 22:57
0

Aptitude does support regular expressions. From man aptitude:

install
   Install one or more packages. The packages should be listed after
   the “install” command; if a package name contains a tilde character
   (“~”) or a question mark (“?”), it will be treated as a search
   pattern and every package matching the pattern will be installed
   (see the section “Search Patterns” in the aptitude reference
   manual).

In fact its search system is sufficiently more powerful than apt's that you have to be more specific in what you want to search for. And aptitude install 'octave?' does try to install every package matching octave ... including those of any other architecture added to your system (say, i386 on an amd64 system). So, restricting the search a bit:

sudo aptitude install '?name (octave*) ?architecture (native)'

or, in short:

sudo aptitude install '~n octave* ~r native'

... which tried to install 360+ packages compared to 38 from just sudo aptitude install octave.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.