Tag Archives: Installation

Playing with Groovy – Tutorial 1

Groovy!  Yes 🙂 , although there are so many languages running on JVM, but the reason i choosed groovy , so that i can effectively write Java EE build automation scripts in Gradle.  Well dont need to confuse yourself with #gradle , #groovy #jvm etc… We are here to explore Groovy.

Groovy is

Object Oriented Scripting Language.

A Loosely Typed Language i.e there is no need to define the data-types for the variables and for the return type of the methods.

Provides the ability to statically type check and statically compile your code for robustness and performance … etc

Ability to Implicit Return

 

Supports Default Parameters , if u dont pass the parameter , the default value of the parameter will be utilized.

 def setPrice(price = 100.00){
    this.price = price
}


Well there are so many pros we can discuss about groovy , lets start our development with downloading Groovy

 

 

References

 

GRADLE – BUILD AUTOMATION – PART 2

Eclipse Integration with Groovy is very simple, here we go!

  1. Using Eclipse Install New Software, install Groovy-Eclipse plug-in from IDE section.
  2. Create new project from eclipse and select new Groovy Project
  3. Create a new Groovy Class with the following code
  4. package com.vogella.groovy.first
    class FirstGroovy {
      static void main(def args){
        def mylist=[1,2,"Lars","4"]
        mylist.each{ println it }
      }
    } 
    
  5. Right-click the Groovy class, and select Run As → Groovy Script from the context menu.

 

Gradle – Build Automation – Part 1

Well Gradle time guys!

I have started to blog down things, i come across developement, first it will help others to troubleshoot and find improvement in my engineering and second to start sharing with community from whom i have learned a lot!

We will be discussing installation of Gradle in this post on Windows 7. Following steps will help in setting up Gradle in your local machine.

 

  1. Download Gradle from Gradle Website
  2. Extract the Zip File to some folder , i m using Drive D:\GradleWare\
  3. Need to Setup Environment Variable , Add GRADLE_HOME with value  D:\GradleWare and add Gradle bin to PATH environment variable i.e PATH value  = …..;D:\GradleWare\bin
  4. Open Command Prompt and Type gradle -v
------------------------------------------------------------
Gradle 2.2.1
------------------------------------------------------------
Build time: 2014-11-24 09:45:35 UTC
Build number: none
Revision: 6fcb59c06f43a4e6b1bcb401f7686a8601a1fb4a
Groovy: 2.3.6
Ant: Apache Ant(TM) version 1.9.3 compiled on December 23 2013
JVM: 1.7.0_45 (Oracle Corporation 24.45-b08)
OS: Windows 7 6.1 amd64