How do I set a variable inside a bash for loop?
- by Isaac Moore
I need to set a variable inside of a bash for loop, which for some reason, is not working for me. Here is an excerpt of my script:
function unlockBoxAll
{
appdir=$(grep -i "CutTheRope.app" /tmp/App_list.tmp)
for lvl in {0..24}
key="UNLOCKED_$box_$lvl"
plutil -key "$key" -value "1" "$appdir/../Library/Preferences/com.chillingo.cuttherope.plist"…