java/HibernateDemo1/build.xml
author František Kučera <franta-hg@frantovo.cz>
Sat, 14 Mar 2009 22:14:59 +0100
changeset 1 55b52df32ec2
parent 0 16a1fc2116d6
permissions -rw-r--r--
JPA: persistence.xml a první mapování
franta-hg@0
     1
<?xml version="1.0" encoding="UTF-8"?>
franta-hg@0
     2
<!-- You may freely edit this file. See commented blocks below for -->
franta-hg@0
     3
<!-- some examples of how to customize the build. -->
franta-hg@0
     4
<!-- (If you delete it and reopen the project it will be recreated.) -->
franta-hg@0
     5
<!-- By default, only the Clean and Build commands use this build script. -->
franta-hg@0
     6
<!-- Commands such as Run, Debug, and Test only use this build script if -->
franta-hg@0
     7
<!-- the Compile on Save feature is turned off for the project. -->
franta-hg@0
     8
<!-- You can turn off the Compile on Save (or Deploy on Save) setting -->
franta-hg@0
     9
<!-- in the project's Project Properties dialog box.-->
franta-hg@0
    10
<project name="HibernateDemo1" default="default" basedir="." xmlns:ear="http://www.netbeans.org/ns/j2ee-earproject/2">
franta-hg@0
    11
    <description>Builds, tests, and runs the project HibernateDemo1.</description>
franta-hg@0
    12
    <import file="nbproject/build-impl.xml"/>
franta-hg@0
    13
    <!--
franta-hg@0
    14
franta-hg@0
    15
    There exist several targets which are by default empty and which can be 
franta-hg@0
    16
    used for execution of your tasks. These targets are usually executed 
franta-hg@0
    17
    before and after some main targets. They are: 
franta-hg@0
    18
franta-hg@0
    19
      pre-init:                 called before initialization of project properties 
franta-hg@0
    20
      post-init:                called after initialization of project properties 
franta-hg@0
    21
      pre-compile:              called before javac compilation 
franta-hg@0
    22
      post-compile:             called after javac compilation 
franta-hg@0
    23
      pre-dist:                 called before archive building 
franta-hg@0
    24
      post-dist:                called after archive building 
franta-hg@0
    25
      post-clean:               called after cleaning build products 
franta-hg@0
    26
      pre-run-deploy:           called before deploying
franta-hg@0
    27
      post-run-deploy:          called after deploying
franta-hg@0
    28
franta-hg@0
    29
    Example of pluging an obfuscator after the compilation could look like 
franta-hg@0
    30
franta-hg@0
    31
        <target name="post-compile">
franta-hg@0
    32
            <obfuscate>
franta-hg@0
    33
                <fileset dir="${build.classes.dir}"/>
franta-hg@0
    34
            </obfuscate>
franta-hg@0
    35
        </target>
franta-hg@0
    36
franta-hg@0
    37
    For list of available properties check the imported 
franta-hg@0
    38
    nbproject/build-impl.xml file. 
franta-hg@0
    39
franta-hg@0
    40
franta-hg@0
    41
    Other way how to customize the build is by overriding existing main targets.
franta-hg@0
    42
    The target of interest are: 
franta-hg@0
    43
franta-hg@0
    44
      do-dist:                archive building
franta-hg@0
    45
      run:                    execution of project 
franta-hg@0
    46
franta-hg@0
    47
    Example of overriding the target for project execution could look like 
franta-hg@0
    48
franta-hg@0
    49
        <target name="run" depends="<PROJNAME>-impl.jar">
franta-hg@0
    50
            <exec dir="bin" executable="launcher.exe">
franta-hg@0
    51
                <arg file="${dist.jar}"/>
franta-hg@0
    52
            </exec>
franta-hg@0
    53
        </target>
franta-hg@0
    54
franta-hg@0
    55
    Notice that overridden target depends on jar target and not only on 
franta-hg@0
    56
    compile target as regular run target does. Again, for list of available 
franta-hg@0
    57
    properties which you can use check the target you are overriding in 
franta-hg@0
    58
    nbproject/build-impl.xml file. 
franta-hg@0
    59
franta-hg@0
    60
    -->
franta-hg@0
    61
</project>