Guest User

Untitled

a guest
Apr 24th, 2018
65
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.16 KB | None | 0 0
  1. #!/bin/bash
  2.  
  3. a=(
  4. 'sudo echo ${foo}'
  5. 'sudo ls -l'
  6. 'ls -l | sudo echo ${foo}'
  7. )
  8.  
  9. foo="hello"
  10.  
  11. for ((i = 0; i < ${#a[@]}; i++))
  12. do
  13. echo $(eval echo ${a[$i]})
  14. done
Add Comment
Please, Sign In to add comment