Build r
Upcoming SlideShare
Loading in...5
×
 

Build r

on

  • 689 views

 

Statistics

Views

Total Views
689
Views on SlideShare
625
Embed Views
64

Actions

Likes
0
Downloads
3
Comments
0

4 Embeds 64

http://jujo00obo2o234ungd3t8qjfcjrs3o6k-a-sites-opensocial.googleusercontent.com 55
http://jug.lv 5
http://www.jug.lv 3
http://jugpreview.tumblr.com 1

Accessibility

Categories

Upload Details

Uploaded via as Microsoft PowerPoint

Usage Rights

© All Rights Reserved

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Processing…
Post Comment
Edit your comment

Build r Build r Presentation Transcript

  • Building tool of new generation
    BuildR
  • BuildR
    Extension of Rake
    Apache project
  • Step 1. Define project
    define 'killer-app' do
    project.version= '0.1.0'
    end
  • Step 2. Add dependencies
    repositories.remote << 'http://www.ibiblio.org/maven2/'
    repositories.remote << 'http://maven.alfresco.com/nexus/content/groups/public/’
    LIBS = struct(
    :alfresco_repo => 'org.alfresco:alfresco-repository:jar:labs:2.1.0',
    :alfresco_core => 'org.alfresco:alfresco-core:jar:labs:2.1.0',
    :alfresco_remote => 'org.alfresco:alfresco-remote-api:jar:labs:2.1.0',
    :apache_collections => 'commons-collections:commons-collections:jar:3.1',
    :apache_beanutils => 'commons-beanutils:commons-beanutils:jar:1.7.0',
    )
  • Step 3. Compile
    define 'al', :layout => ab_layout do
    project.version = 1.5
    compile.options.target = '1.5'
    compile.with LIBS
    end
  • Step 4. Package
    define 'al', :layout => ab_layout do
    project.version = 1.5
    compile.options.target = '1.5'
    compile.with LIBS
    package :jar
    end
    $ buildr package
  • Step 5. Directory structure
    ab_layout = Layout.new
    ab_layout[:source, :main, :java] = 'src'
    ab_layout[:source, :main, :resources] = 'resources'
    define 'al', :layout => ab_layout do
    project.version = 1.5
    compile.options.target = '1.5'
    compile.with LIBS
    package :jar
    end
  • Step 6. Add custom task
    define 'al', :layout => ab_layout do
    project.version = 1.5
    compile.options.target = '1.5'
    compile.with LIBS
    task :run => :compile do
    system 'java -cp target/classes
    org.apache.killer.Main'
    end
    end
  • Step 7. Test
    define 'al', :layout => ab_layout do
    project.version = 1.5
    compile.options.target = '1.5'
    compile.with LIBS
    test.with'commons- ollections:commons- collections:jar:3.2'
    test.using:testng
    end
  • Step 8. Call java
    task :generate do
    p 'calling ant..'
    Java.org.apache.tools.ant.Main.main( ['-file',
    'build.xml', 'generate', '-Dserver=localhost'] )
    end
  • Languages
    Java
    Scala
    Groovy
    Ruby
  • Other stuff
    Interactive Shell (JavaRebelsupport)
    IDE project file generation
    Cobertura, Emma, Jdepend