It seems likely that the firefox
command would block the script from progressing until it exited. Simply push it into the background and your script can progress:
firefox http://www.google.de &
On a tangential note, you might also want to look at the -no-remote
for Firefox. This will stop the command interacting with any existing Firefox instances in your DISPLAY.
While we're talking tangents, the firefox
command has a few helper arguments that --along with -no-remote
— can help you target the new window.
For instance, you can set a specific class name and then have Compiz handle the resizing automagically. And wmctrl -x <WM_CLASS>
will let you target a class rather than an ID. Probably more robust than targeting Window names or IDs too.