- Notifications
You must be signed in to change notification settings - Fork0
eddyson-de/groovy
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
Groovy is a powerful, optionally typed and dynamic language, with static-typing and static compilation capabilities, for the Java platform aimed at multiplying developers’ productivity thanks to a concise, familiar and easy to learn syntax.
It integrates smoothly with any Java program, and immediately delivers to your application powerful features, including scripting capabilities, Domain-Specific Language authoring, runtime and compile-time meta-programming and functional programming.
You don’t need the source code to use Apache Groovy but if you wish to explore its inner workings or build it for yourself there are two ways to obtain the source files.
Apache Groovy uses Git. The official Git repository is at:
https://git-wip-us.apache.org/repos/asf/groovy.git
And a mirror is hosted on Github:
https://github.com/apache/groovy
The Github mirror is read-only and provides convenience to users and developers to explore the code and for the community to accept contributions via Github pull requests.
Simplygit clone
the repo (or the repo you forked via the github website) and you will have the complete source.
Alternatively, you can download the source distribution and unpack it.
If obtaining the source from this distribution and you intend to build from source,you also need todownload and installGradle and execute one bootstrap step.At the top directory of your unpacked source, you need to run the command:
gradle
This sets up the Gradle wrapper and from then on you just need thegradlew
command instead ofgradle
.
To build you will need:
To build everything using Gradle:
gradlew clean dist
Note: The gradlew command automatically downloads the correct Gradle version if needed, you do not need to download it first.
This will generate a distribution similar to the zip you can download on the Groovy download page.
To build everything and launch unit tests, use:
gradlew test
If you want to launch one unit test, use this. <TestClassName> is likegroovy.GroovyMethodsTest
.
gradlew :test --tests <TestClassName>
To build from IntelliJ IDEA:
gradlew jar idea
Then open the generated project in IDEA.
To build from Eclipse:
gradlew jar eclipse
Then open the generated project and the generated subprojects in Eclipse. But be aware that Eclipse tends to be more limited in its ability to reproduce a Gradle build structure. The generated project files may contain a circular dependency which may or may not prevent Eclipse from using them. It depends on the Eclipse version, if this is an issue or not.
To build the documentation (Groovy Language Documentation):
gradlew assembleAsciidoc
All code samples of the documentation guide are pulled from actual test cases. To run a single documentation test case, take for examplesrc/spec/test/semantics/PowerAssertTest.groovy
gradlew testSinglePowerAssertTest
(Note the omission of package name: class issemantics.PowerAssertTest
but onlyPowerAssertTest
is added totestSingle
.)
The Groovy build supports the JVM instructioninvokedynamic
. If you want to build Groovy with invokedynamic, you can use the project propertyindy
:
gradlew -Pindy=true clean test
Please note that the following Gradle tasks generate both indy and non indy variants of the jars, so you don’t need to use the system property:
dist
install
uploadArchives
Groovy is licensed under the terms of theApache License, Version 2.0
About
Mirror of Apache Groovy
Resources
License
Stars
Watchers
Forks
Packages0
Languages
- Java57.7%
- Groovy39.4%
- GAP1.1%
- HTML0.9%
- CSS0.7%
- Shell0.1%
- Other0.1%