- Replace leading tabs with spaces
- Add space before opening curly brace
- Optimize imports using shared .idea/codeStyleSettings.xml
- Do not align assignments on equals sign
- Remove unnecessary extra newlines
Running `gradle build` within ethereumj-core will now produce -sources
and -javadoc jars in `build/libs`, alongside the already existing
classes jar. Run `gradle install` to install these artifacts to the
local `~/.m2` repository.
This change ensures that all Javadoc syntax, reference, html errors, etc
are reported at the commandline during the gradle build, but warnings
for missing Javadoc elements (e.g. no @return tag, @param tags, etc) are
suppressed. `man javadoc` for details.
See updated ethereumj-studio/README.md for details. Note that this
commit removes the `build-post-package.xml` ant file (for now) to
simplify the Gradle arrangement. This functionality can be re-introduced
later and more simply using Gradle's native DSL. In the meantime, both
the -core and -studio projects can be run using `gradle run` or run as
executable jars by running `gradle shadowJar` followed by the usual
`java -jar` execution of the resulting `-all` jar file found in each
project's respective `build/libs` directory.
- Convert ethereumj-studio build from Maven to Gradle as well
- Extract common build elements to top-level build.gradle
- Update top-level README accordingly
Apply Gradle's 'maven' plugin in order to support `./gradlew install`
task, similar to `mvn install` for building and copying artifacts to the
users local ~/.m2 repository.
After porting the build from Maven to Gradle (see prior commits), the
org.ethereum.serpent.ParserGenerator class is no longer necessary as the
configuration of the antlr compiler that happened in this class now
happens directly in build.gradle. This class is thus removed in this
commit.
The plexus FileUtils class introduced by the antlr4 Maven plugin had
also been used in several locations in the codebase, probably just for
reasons of convenience. These uses have been replaced with Spring's
FileSystemUtils in order to allow for dropping the dependency on the
antlr4 Maven plugin entirely.
ethereumj-core depends on elements specific to the JUnit 4.11 API, but (for
reasons that can only be assumed dubious) json-simple:1.1.1 transitively
includes JUnit 4.10. At the command line, Gradle handles this cleanly,
and gives ethereumj-core's direct dependence on 4.11 the precedence it
deserves. However, IDEA gets confused and gives 4.10 precedence. This
change explicitly excludes the transitive dependency from
json-simple->junit:4.10, eliminating the issue completely.
Previously, sources generated from the serpent antlr grammar in
ethereumj-core/src/main/antlr4 were output into the build/generated-src
directory by default. This worked from the command line without issue,
but caused issues within IDEA, because the entirety of the 'build'
directory is excluded from compilation by default when working with a
Gradle-based project in IDEA.
This change simplifies the arrangement by writing these antlr-generated
sources to the src/gen/java. A .gitignore file has been added to ensure
that transient source files don't accidentally get checked in. A readme
file has been added to explain the situation to the uninitiated.