Bash Script Loop Through Array Javascript Push Method