[Script] Update For Linux

Discussion in 'Bukkit Discussion' started by AbsolutePolak, Jan 15, 2011.

Thread Status:
Not open for further replies.
  1. Offline

    AbsolutePolak

    Well i have created a script thanks to ScytheX10 for his commands on downloading and building. Now this works for debian only as far as i am concerned.
    1. Extract the script onto your home directory
    2.Open up terminal and install maven2 and git. (my example, sudo apt-get install maven2 git)
    3. Type in
    Code:
    chmod +x update.sh
    (or alternatively, open up the properties of the file and set it as an executable.)
    4. Type in
    Code:
    ./update.sh
    5. Your done, the snapshot will be in your home directory.

    Now to only update, just repeat step 4-5.
     

    Attached Files:

  2. Offline

    feverdream

    A for effort..
    F for fail.

    You have a hard coded home path in the first script that nobody except "honey" will have, and an assumption that the system uses apt-get in the next.. so many distroes will not be able to use it.
     
  3. Offline

    ScytheX10

    try $HOME (as in, the HOME variable) for scripts.
    Code:
    cd $HOME
    mv /bla/bla $HOME/bladir
    also, provide an argument for what repo/package system they use.
    so they can start the script ./script apt-get or ./script yum etc
     
  4. Offline

    AbsolutePolak

    Thank you scythe and fever, i have updated the instructions and the update script. Please tell me what you think :)
     
  5. Offline

    TnT Retired Staff

    Easier update script:

    Code:
    #!/bin/sh
    wget "http://artifacts.lukegb.com/artifactory/plugins-snapshot/org/bukkit/craftbukkit/0.0.1-SNAPSHOT/craftbukkit-0.0.1-SNAPSHOT.jar"
    rm craftbukkit.jar
    mv craftbukkit-0.0.1-SNAPSHOT.jar craftbukkit.jar
    java -Xms1024M -Xmx1024M -jar craftbukkit.jar nogui
    That gives you the latest build every time you start up your server.

    Note: script assumes you run it from your main Minecraft server directory. For me, this is /opt/craftbukkit.
     
  6. Offline

    feverdream

     
Thread Status:
Not open for further replies.

Share This Page