Writing plugin version to plugin.xml when built on TeamCity
This commit is contained in:
Generated
+8
@@ -50,6 +50,14 @@
|
||||
<maximumStackSize value="2" />
|
||||
<properties />
|
||||
</buildFile>
|
||||
<buildFile url="file://$PROJECT_DIR$/plugin_pre_build.xml">
|
||||
<additionalClassPath />
|
||||
<antReference projectDefault="true" />
|
||||
<customJdkName value="" />
|
||||
<maximumHeapSize value="128" />
|
||||
<maximumStackSize value="2" />
|
||||
<properties />
|
||||
</buildFile>
|
||||
</component>
|
||||
</project>
|
||||
|
||||
|
||||
Generated
+6
@@ -7,6 +7,12 @@
|
||||
<target>renamePluginZip</target>
|
||||
</options>
|
||||
</properties>
|
||||
<properties id="ant-preprocessing">
|
||||
<options enabled="true">
|
||||
<file>file://$PROJECT_DIR$/plugin_pre_build.xml</file>
|
||||
<target>writeVersionToPluginXml</target>
|
||||
</options>
|
||||
</properties>
|
||||
<root id="archive" name="KotlinPlugin.zip">
|
||||
<element id="directory" name="Kotlin">
|
||||
<element id="directory" name="lib">
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<idea-plugin version="2">
|
||||
<name>Kotlin</name>
|
||||
<description>Kotlin language support</description>
|
||||
<version>1.0</version>
|
||||
<version>@snapshot@</version>
|
||||
<vendor>JetBrains</vendor>
|
||||
|
||||
<application-components>
|
||||
|
||||
@@ -5,7 +5,6 @@
|
||||
|
||||
<target name="renamePluginZip">
|
||||
<!-- Rename the zip to kotlin-plugin-${build}.zip-->
|
||||
<echo message="${artifact.output.path}"/>
|
||||
<move file="${artifact.output.path}/KotlinPlugin.zip" tofile="${artifact.output.path}/kotlin-plugin-${build.number}.zip">
|
||||
</move>
|
||||
</target>
|
||||
|
||||
@@ -0,0 +1,24 @@
|
||||
<project name="Kotlin Plugin Pre-build Step">
|
||||
|
||||
<property name="artifact.output.path" value="${basedir}/out/artifacts/KotlinPlugin"/>
|
||||
<property name="build.number" value="snapshot"/>
|
||||
|
||||
<!-- Sets ${running.locally} to true if the ${build.number} is "snapshot" -->
|
||||
<target name="checkLocal">
|
||||
<condition property="running.locally">
|
||||
<equals arg1="${build.number}" arg2="snapshot"/>
|
||||
</condition>
|
||||
</target>
|
||||
|
||||
<target name="writeVersionToPluginXml" depends="checkLocal" unless="running.locally">
|
||||
<copy file="idea/src/META-INF/plugin.xml" tofile="idea/src/META-INF/plugin.xml-version">
|
||||
<filterchain>
|
||||
<replacetokens>
|
||||
<token key="snapshot" value="${build.number}"/>
|
||||
</replacetokens>
|
||||
</filterchain>
|
||||
</copy>
|
||||
<copy file="idea/src/META-INF/plugin.xml-version" tofile="idea/src/META-INF/plugin.xml" overwrite="true"/>
|
||||
<delete file="idea/src/META-INF/plugin.xml-version" quiet="true"/>
|
||||
</target>
|
||||
</project>
|
||||
Reference in New Issue
Block a user