Actifsource

#6938 Compile actifsource project by ant

Actifsource code generator for any programming language
If a metamodel was created in an Actifsource project, this usually contains java code which must be compiled before generation or validation. It should therefore be possible to compile such a project via Ant in order to integrate it into the CI/CD pipeline.

The corresponding Ant file can be generated automatically via Project Explorer 'Export->Actifsource->Ant BuildFiel Export':

6938 1 exportant-compilation-1

The Ant file now contains the following two essential targets:

1. export-classpath

This target can be used to collect the class path of a project, which is required to compile the project:

6938 2 exportant-compilation-2

The export dependency can now be configured with the following properties:

  • classpathproperty: The project classpath is written to the property and can be used in the antscript. 
  • classpathseparator: The ClassPath separator (default ;) can be customized. 
  • classpathfile: The project classpath is written to the file.

6938 3 Ant5


  • classpathmapproperty: The Project ClasspathMap is written to the property and can be used in the antscript. 
  • classpathmapfile: The Project ClasspathMap is written to the file.

6938 4 Ant10

  • dependencytreeproperty: The project dependencytree is written to the property and can be used in the antscript. 
  • dependencytreefile: The project dependencytree is written to the file.

6938 5 Ant11

2. compile-project

The project can now be compiled using this target:

The 'classpathproperty' property from the 'export-classpath' target is used for the ClassPath.

6938 6 exportant-compilation-3

On github there is an example (Use the ant build file 'asbuild.dynamic.loading.compile_validate_generate.xml'):
  • ​See ​https://github.com/actifsource/ch.actifsource.example.ant