Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

Spoonless

macrumors newbie
Original poster
Apr 26, 2012
1
0
Hey guys, newbie here.

I was wondering if someone could help me with a scripting problem I've been having.

I recently installed a Bukkit Minecraft server, but for it to work properly, I need to first fire up my "Portmap" app to port forward, and then run the .command files to start the server. Everything works like a charm, but I've been trying to modify that .command file so that it opens Portmap AND starts the server (in that order, otherwise I guess the server wont start properly.)

I have tried googling but to no avail.

Here's the code from that .command file, from what I can tell it doesn't seem to be too complicated...

Code:
#!/bin/bash
cd "`dirname "$0"`"
java -Xmx1024M -Xms1024M -jar craftbukkit.jar nogui

Any thoughts?
 

kryten2

macrumors 65816
Mar 17, 2012
1,114
99
Belgium
Code:
#!/bin/bash
# change path to where you copied Portmap
open "/Applications/Port Map.app/"
# Give it a few seconds, comment it if not needed
sleep 2
cd "`dirname "$0"`"
java -Xmx1024M -Xms1024M -jar craftbukkit.jar nogui
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.