[BUILDTOOLS-281] Unable to run BuildTools with successful result. No matter what. Created: 26/Nov/16  Updated: 17/Nov/17  Resolved: 17/Nov/17

Status: Resolved
Project: BuildTools
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Bug Priority: Major
Reporter: Michael Assignee: Unassigned
Resolution: Done Votes: 1
Labels: BuildTools, failed, spigot, stupid
Environment:

Ubuntu 16.04 LTS.
VPS under Intel(R) Xeon(R) CPU E5-2690 0 @ 2.90GHz
2 cores of 8 available.
4Gb Ram.


Attachments: Text File BuildTools.log.txt    

 Description   

No matter what I do I always get errors during the BuildTools run. I have the latest version, and am installing in a clean directory. I always set " git config --global --unset core.autocrlf ".

The output is always something to do with failing a patch process.

There's not much I can do if BuildTools is using other parts of the O/S incorrectly, eg Git for example. This is the end of the log , entire log is attached. I would really appreciate help with this!

[INFO] — maven-install-plugin:2.4:install (default-install) @ craftbukkit —
[INFO] Installing /home/maniax/buildtools/CraftBukkit/target/craftbukkit-1.10.2-R0.1-SNAPSHOT.jar t o /home/maniax/.m2/repository/org/bukkit/craftbukkit/1.10.2-R0.1-SNAPSHOT/craftbukkit-1.10.2-R0.1-S NAPSHOT.jar
[INFO] Installing /home/maniax/buildtools/CraftBukkit/dependency-reduced-pom.xml to /home/maniax/.m 2/repository/org/bukkit/craftbukkit/1.10.2-R0.1-SNAPSHOT/craftbukkit-1.10.2-R0.1-SNAPSHOT.pom
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 01:02 min
[INFO] Finished at: 2016-11-26T03:48:34+00:00
[INFO] Final Memory: 22M/621M
[INFO] ------------------------------------------------------------------------
Rebuilding Forked projects....
applyPatches.sh: 7: applyPatches.sh: function: not found
fatal: ambiguous argument '': unknown revision or path not in the working tree.
Use '--' to separate paths from revisions, like this:
'git <command> [<revision>...][<file>...]'
Resetting to ...
error: Could not remove config section 'remote.upstream'
fatal: ambiguous argument 'upstream/upstream': unknown revision or path not in the working tree.
Use '--' to separate paths from revisions, like this:
'git <command> [<revision>...][<file>...]'
Applying patches to ...
fatal: Resolve operation not in progress, we are not resuming.
fatal: could not open '/home/maniax/buildtools/Spigot/-Patches/*.patch' for reading: No such file o r directory
Something did not apply cleanly to .
Please review above details and finish the apply then
save the changes with rebuildPatches.sh
Error compiling Spigot. Please check the wiki for FAQs.
If this does not resolve your issue then please pastebin the entire BuildTools.log.txt file when se eking support.
java.lang.RuntimeException: Error running command, return status !=0: [/bin/sh, applyPatches.sh]
at org.spigotmc.builder.Builder.runProcess(Builder.java:552)
at org.spigotmc.builder.Builder.main(Builder.java:434)



 Comments   
Comment by TJ [ 13/Aug/17 ]

 

Comment by WoJ [ 10/Aug/17 ]

@TJ: thank you - this workaround solved my problem. I would never have found out.

Comment by TJ [ 17/Mar/17 ]

Finally, after maybe three months, i found a workaround. I reverted my tools version to 47, what usually runs when you do --rev 1.10.2. And it worked. Also, I changed my .gitconfig file in the home directory to match my actual username and email - that shouldn't have changed anything, but who knows. Hopefully that helped! 

Comment by TJ [ 07/Jan/17 ]

where? I am confused... I have the same bug - and while I have run spigot servers before I have never encountered this one... The only difference between this server and any other one I have run is that it is in 1.10.2

Comment by Stephane [ 29/Dec/16 ]

THANK YOU very much !

many thousands days i am looking for that !!!!

i am saved

Comment by Cat73 [ 06/Dec/16 ]

Add a "export SHELL=/bin/bash" to solve the problem.

Comment by Michael [ 26/Nov/16 ]

FYI,

I had previously tried revision 1.10, and 1.8 instead of current (1.11). And these failed in the same manner.

It should be noted that I am now receiving a different error when specifically trying to build 1.11. I have the 1.10 JAR files now and will be using them but will still be trying to build 1.11. Why this is not working is due to some other random error.

**UPDATE**

As I was writing this, I attempted to build the 1.11 revision over and over again. Failure after failure was finally rewarded with a successful build. How on gods own planet does that happen? Nothing changed between build attempts. I simply deleted the build directory, copied BuildTools.jar into a new directory and re-ran the build command. Over and Over again. And finally, just randomly, it worked.

Thats what you get, I guess, for trusting online source code.

Cheers,

Comment by Michael [ 26/Nov/16 ]

So here's some crazy findings.
I followed the guide over here https://www.vultr.com/docs/setup-spigot-on-ubuntu regarding ensuring the swap file was setup in the VPS. In addition to this I ran this command at the prompt as root:

export MAVEN_OPTS "-Xmx1G"

and tried building as root again but with more java options:

java -Xms512m -Xmx2g -jar BuildTools.jar --rev 1.10

and this time (holy cr*p), after about 200 previously failed attempts and google searches and trying everything at the console, it finally worked.

"Success! Everything compiled successfully. Copying final .jar files now."

This sort of stupid cr*p should never happen. the VPS I'm on has 4gig of Ram, and a crazy amount of hard disk space. So why did this happen? Who cares, right?

Cheers.

Comment by Michael [ 26/Nov/16 ]

Muahaha good luck.

Generated at Sat Dec 13 14:30:09 UTC 2025 using Jira 10.3.13#10030013-sha1:56dd970ae30ebfeda3a697d25be1f6388b68a422.