Score:0

Why does an aterisk or a line of asterisks as a bash command return "boost_1_69_0: command not found"?

ec flag

I am a bit confused and amusued but I just accidentally pressed my keyboard and typed:

*******************************************

to which my Ubuntu 22 bash returned:

me@pc:~$ *******************************************
boost_1_69_0: command not found

I tried with multple amounts of * and the result is the same.

Score:3
cn flag

See ls -l and you will see "boost_1_69_0" in the list as the 1st alphabetical file or directory.

The amount of *'s does not matter. bash sees the wildcards and tries to execute it for all of the contents of your active directory and then finds out it can not make sense of it.

I have "bin" as the 1st one and it will for me complain about "bin":

rinzwind@schijfwereld:~$ ls -l
total 8
drwxrwxr-x 2 rinzwind rinzwind 4096 apr 23 11:24 bin
drwx------ 5 rinzwind rinzwind 4096 apr 18 22:19 snap
rinzwind@schijfwereld:~$ *
Command 'bin' not found, did you mean:
  command 'tin' from deb tin (1:2.6.2-1build1)
  command 'ben' from deb ben (0.10.1ubuntu1)
  command 'bing' from deb bing (1.3.5-5)
  command 'bip' from deb bip (0.9.3-1)
  command 'win' from deb wily (0.13.42-1)
  command 'din' from deb din (56-1)
Try: sudo apt install <deb name>

Use set -x if you want more detailed info about what is happening (set +x to revert that).

Oh and this becomes funky if you had done:

./*

and have this inside "1":

rinzwind@schijfwereld:/discworld/tmp$ cat 1
#!/bin/bash
rinzwind@schijfwereld:/discworld/tmp$ ./*
rinzwind@schijfwereld:/discworld/tmp$ 

and it will execute it ;)

C. Crt avatar
ec flag
You're right! I forgot to check the content of the directory I was in. Thank you and sorry for the stupid question.
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.