Dev:Core FAQ

From Valkyrien Skies Wiki

General

All of my resources are missing!

Go to Build, Execution, Deployment > Build Tools > Gradle and make sure that Build and run using: IntelliJ IDEA is set and not Build and run using: Gradle

I don't like IntelliJ, what can I do?

You have many options:

  1. Suck it up and use it.
  2. Use gradlew and a text editor of choice, not too bad but prone to small errors.
  3. Use eclipse (do not do it, it sucks and is a memory/cpu hog)

Gradle

./gradlew setupDecompWorkspace is failing

  1. Delete the .gradle folder inside of your project.
  2. Delete your global .gradle folder.

How do you check the size of dependencies?[1]

Copy and paste the following code into your build.gradle and then run ./gradlew depsize on your command line.

task depsize  {
    doLast {
        final formatStr = "%,10.2f"
        final conf = configurations.default
        final size = conf.collect { it.length() / (1024 * 1024) }.sum()
        final out = new StringBuffer()
        out << 'Total dependencies size:'.padRight(45)
        out << "${String.format(formatStr, size)} Mb\n\n"
        conf.sort { -it.length() }
            .each {
                out << "${it.name}".padRight(45)
                out << "${String.format(formatStr, (it.length() / 1024))} kb\n"
            }
        println(out)
    }
}