Skip to main content
2 votes
Accepted

bash: hash: hashing disabled

If you're getting that message, it means that you have hashing disabled and that something in the script being sourced is running the hash built-in; in this specific case, that script is running hash -...
kos's user avatar
  • 37.8k
2 votes
Accepted

How to use asterisk (*) in bash array

I don't think you can - safely1 - do what you want to in bash. In bash (as well as POSIX sh and ksh), double quoting of parameter expansions (including array expansions like "{my_array[@]}" ...
steeldriver's user avatar
1 vote

How to use asterisk (*) in bash array

Use the asterisk when populating the array, but don't populate it one element at a time: my_array=(cp /tmp/hello/* /tmp/world) "${my_array[@]}" Or use the += operator to exapand the array: ...
choroba's user avatar
  • 9,718

Only top scored, non community-wiki answers of a minimum length are eligible