-
Notifications
You must be signed in to change notification settings - Fork 18
/
Cql.Targets.xml
20 lines (19 loc) · 998 Bytes
/
Cql.Targets.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
<?xml version="1.0" encoding="utf-8" ?>
<Project>
<ItemGroup>
<ElmFiles Include="$(MSBuildProjectDirectory)\..\Elm\Json\*.json"></ElmFiles>
</ItemGroup>
<Target Name="Download CQL to ELM CLI via Maven" Inputs="Build\pom.xml" Outputs="Build\target\dependency\cql-to-elm-cli-2.11.0.jar">
<Exec Command="mvn -f Build\pom.xml dependency:copy-dependencies"></Exec>
</Target>
<Target Name="CQL to ELM"
DependsOnTargets="Download CQL to ELM CLI via Maven"
AfterTargets="Build">
<Message Text="Converting CQL to ELM"/>
<Exec Command="java -classpath Build\target\dependency\* org.cqframework.cql.cql2elm.cli.CqlTranslator -input $(MSBuildProjectDirectory)\input -f JSON -output $(MSBuildProjectDirectory)\..\Elm\Json -locators true -result-types true"/>
</Target>
<Target Name="Delete ELM" AfterTargets="Clean">
<Message Text="Deleting ELM files...$(MSBuildProjectDirectory)\..\Elm\Json\*.json"></Message>
<Delete Files="@(ElmFiles)" />
</Target>
</Project>