Three examples what I type in bash command line after prompt and what are the responses:
'xxx' "aaa"
response:
bash: xxx: command not found
ok.
/bin/bash -c 'xxx'
response:
/bin/bash: line 1: xxx: command not found
ok.
/bin/bash -c 'xxx' "aaa"
response:
aaa: line 1: xxx: command not found
unexpainable.
It looks like if "aaa" would be the shell reporting this error.
It took me many days for searching what is the cause in my script.
Regards
bash -c? (2) In case you really didn't, what is the content ofxxx? – Kamil Maciorowski Dec 26 '22 at 18:29bash -c: yes, sure, I can. Forbashwithout-cI cannot, I'm curious myself. Can you please respond to my first comment? – Kamil Maciorowski Dec 28 '22 at 12:39bashthen replaceaaawithbash. – Kamil Maciorowski Dec 28 '22 at 12:56bash -cto name itselfbash, do not usebash -c '… "$0" …' aaa. Usebash -c '… "$1" …' bash aaa. Weeks ago I gave you the same link. – Kamil Maciorowski Dec 28 '22 at 13:22man bashand the explanation of-cin the first few paragraphs (especially the part relating to how$0is set). So whatever you pass asaaawill end up in$0, it has no other effect. – nohillside Dec 28 '22 at 13:26man bash. – Kamil Maciorowski Dec 28 '22 at 13:35