Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Complete project migration to Gradle #190

Closed
wants to merge 27 commits into from
Closed

Complete project migration to Gradle #190

wants to merge 27 commits into from

Conversation

eshepelyuk
Copy link
Contributor

Closes #178

  1. Removed all Ant scripts leftovers,
  2. Removed CVS leftovers.
  3. Changed file structure to comply with standard Maven / Gradle directory structure
    i.e src/main/java, src/main/resources, etc
  4. Code coverage with JaCoCo
    • run it with ./gradlew jacocoTestReport
    • find report at build/reports/jacoco
  5. ZIP archive creation with Gradle
    • run it with ./gradlew distZip
    • find ZIP at build/distributions
  6. More tests can be run directly from IDE, e.g. benchmarks tests

@@ -55,7 +55,10 @@ More resources if you get stuck:

### How to Build

Rhino builds with `Gradle`. Here are some useful tasks:
Rhino builds with `Gradle`. You don't need to install `Gradle` locally to build `Rhino` thanks to [Gradle wrapper](http://gradle.org/docs/current/userguide/gradle_wrapper.html)
Just clone project from `GitHub` and use provided `gradlew.sh` or `gradlew.bat` for `Linux` / `Mac OS` or `Windows` accordingly.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Minor correction: even though file for *nix is a bash script, it's called just gradlew, not gradlew.sh.

@@ -64,7 +64,7 @@ André Bargull (60):
* Add missing @Override annotations
* Add missing generic type info to deprecatedsrc/
* Add missing generic type info to toolsrc/
* Add missing generic type info to testsrc/
* Add missing generic type info to src/test/resources/
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Another minor thing: I don't think a changelog should be updated -- even if folder is no longer there, it certainly existed when it was written.

@gbrail
Copy link
Collaborator

gbrail commented May 15, 2015

OK, I will look, but I am going to take the time to make sure this is really stable first since ant has been with the project for so long. Thanks for doing this!

@gbrail
Copy link
Collaborator

gbrail commented Jun 8, 2015

Thank you very much for all the Gradle work, but here's why I have been hesitant to merge this:

I understand rationally that Git will do lots of smart things when we re-name the source directories, but I guess until I try it I won't be comfortable with that. There is a queue of pull requests, plus lots of people who have other versions of the project, plus some other forks on GitHub, and I fear that if we re-name those directories we are going to waste a lot of time manually merging things.

Either I'm not yet convinced of the power of git, or this is a real concern.

Is there a way that I can cherry-pick the changes here that remove ant and add the other improvements without re-naming everything?

@eshepelyuk
Copy link
Contributor Author

Unfortunately I don't know how to do it using cherry picks.
As an other option - you could merge all "active" PRs, release new Rhino version.
Then announce directory structure change and only then merge this PR.

@gbrail gbrail added this to the Release 1.7.8 milestone Jun 17, 2015
Conflicts:
	gradle.properties
	maven/maven-pom.xml
	maven/maven-snapshot-deploy.sh
	maven/maven-staging-deploy.sh
	src/test/java/org/mozilla/javascript/benchmarks/V8Benchmark.java
Conflicts:
	build.properties
	gradle.properties
	maven/maven-pom.xml
	src/manifest
Conflicts:
	gradle.properties
	maven/maven-snapshot-deploy.sh
	src/test/java/org/mozilla/javascript/tests/harmony/ArrayFindIndexTest.java
	src/test/java/org/mozilla/javascript/tests/harmony/ArrayFindTest.java
	src/test/java/org/mozilla/javascript/tests/harmony/StringCodePointAtTest.java
	src/test/java/org/mozilla/javascript/tests/harmony/StringEndsWithTest.java
	src/test/java/org/mozilla/javascript/tests/harmony/StringIncludesTest.java
	src/test/java/org/mozilla/javascript/tests/harmony/StringNormalizeTest.java
	src/test/java/org/mozilla/javascript/tests/harmony/StringRepeatTest.java
	src/test/java/org/mozilla/javascript/tests/harmony/StringStartsWithTest.java
	src/test/resources/jstests/harmony/array-findIndex.js
	src/test/resources/tests/lc2/Methods/method-006.js
	testsrc/build.xml
Conflicts:
	gradle.properties
	maven/maven-snapshot-deploy.sh
	src/test/java/org/mozilla/javascript/tests/harmony/ArrayFindIndexTest.java
	src/test/java/org/mozilla/javascript/tests/harmony/ArrayFindTest.java
	src/test/java/org/mozilla/javascript/tests/harmony/StringCodePointAtTest.java
	src/test/java/org/mozilla/javascript/tests/harmony/StringEndsWithTest.java
	src/test/java/org/mozilla/javascript/tests/harmony/StringIncludesTest.java
	src/test/java/org/mozilla/javascript/tests/harmony/StringNormalizeTest.java
	src/test/java/org/mozilla/javascript/tests/harmony/StringRepeatTest.java
	src/test/java/org/mozilla/javascript/tests/harmony/StringStartsWithTest.java
	src/test/resources/jstests/harmony/array-findIndex.js
	src/test/resources/tests/lc2/Methods/method-006.js
	testsrc/build.xml
@eshepelyuk
Copy link
Contributor Author

Hello @gbrail
FYI I've merged current master to this branch and also update Gradle to latest version 2.6.
So this branch reflect all the latest changes from master and completely built with Gradle including all the improvements described above.

@gbrail
Copy link
Collaborator

gbrail commented Sep 2, 2015

I've cherry-picked most of these changes, so that the gradle code that we have in master does everything that we need it to do. (It does not actually publish the final build to Maven Central -- that requires signing things and the Gradle recipe for that was complex -- but ant didn't do it right either.)

Thanks for leading the way with Gradle!

I'm ready to get rid of ant...

However, I don't think that we should re-name the project directories. There are always a few PRs in the queue and if we re-name the classes, I fear that we are going to end up with a big mess when we try to merge.

@eshepelyuk eshepelyuk closed this Aug 16, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Implement build system with Gradle
3 participants