I have the following class. It allows me to execute commands through java.
public class ExecuteShellCommand { public String executeCommand(String command) {
each command you are running has its own bash shell, so once you cd to that directory and for next command you are opening new bash shell
try changing your command to
ls bin