update new url for pre.astrid-dev

pull/14/head
Tim Su 13 years ago
parent 38bcd361f2
commit aa176785a8

@ -1,8 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
<!--
** Copyright (c) 2012 Todoroo Inc
**
** See the file "LICENSE" for the full license governing this code.
** See the file "LICENSE" for the full license governing this code.
-->
<project name="astrid" default="help">
@ -59,10 +59,10 @@
<!-- extension targets. Uncomment the ones where you want to do custom work
in between standard targets -->
<target name="-set-mode-check" depends="">
<fail if="build.is.mode.set"
message="Cannot run two different modes at the same time. If you are running more than one debug/release/instrument type targets, call them from different Ant calls." />
</target>
<target name="-set-mode-check" depends="">
<fail if="build.is.mode.set"
message="Cannot run two different modes at the same time. If you are running more than one debug/release/instrument type targets, call them from different Ant calls." />
</target>
<target name="-pre-build" depends="get-version, copy-sources, setup-lite, updatekeys, updatekeys-release, update-market-strategy">
<mkdir dir="gen" />
@ -71,7 +71,7 @@
</target>
<target name="-post-astrid-build" depends="teardown-lite" />
<target name="copy-sources">
<delete dir="${source.dir}" />
<mkdir dir="${source.dir}" />
@ -96,7 +96,7 @@
select="\1" />
<echo message="Astrid: version ${manifest.version.code}, named ${manifest.version.name}" />
</target>
<target name="warnings">
<echo>====== context classes without setContext =====</echo>
<exec executable="sh">
@ -123,7 +123,7 @@
<replaceregexp file="${source.dir}/com/todoroo/astrid/actfm/sync/ActFmInvoker.java"
match="APP_SECRET = .*"
replace="APP_SECRET = &quot;${apikey.actfm.secret}&quot;;" />
<replaceregexp file="${source.dir}/com/todoroo/astrid/taskrabbit/TaskRabbitActivity.java"
match="TASK_RABBIT_CLIENT_ID = .*"
replace="TASK_RABBIT_CLIENT_ID = &quot;${apikey.taskrabbit.clientid}&quot;;" />
@ -133,31 +133,31 @@
<replaceregexp file="${source.dir}/com/todoroo/astrid/taskrabbit/TaskRabbitActivity.java"
match="TASK_RABBIT_URL = .*"
replace="TASK_RABBIT_URL = &quot;${apikey.taskrabbit.url}&quot;;" />
<replaceregexp file="${source.dir}/com/todoroo/astrid/taskrabbit/TaskRabbitMapActivity.java"
match="MAPS_API_KEY = .*"
replace="MAPS_API_KEY = &quot;${apikey.maps}&quot;;" />
<replaceregexp file="${source.dir}/com/todoroo/astrid/gtasks/api/GtasksInvoker.java"
match="API_KEY = .*"
replace="API_KEY = &quot;${apikey.gtasks}&quot;;" />
<replaceregexp file="${source.dir}/com/todoroo/astrid/utility/Constants.java"
match="AWS_SECRET_KEY_ID = .*"
replace="AWS_SECRET_KEY_ID = &quot;${apikey.amazon.secret}&quot;;" />
<replaceregexp file="${source.dir}/com/todoroo/astrid/service/abtesting/ABTestInvoker.java"
match="API_KEY = .*"
replace="API_KEY = &quot;${apikey.analytics.id}&quot;;" />
<replaceregexp file="${source.dir}/com/todoroo/astrid/service/abtesting/ABTestInvoker.java"
match="API_SECRET = .*"
replace="API_SECRET = &quot;${apikey.analytics.secret}&quot;;" />
<antcall target="updatekeys-lite" />
<replaceregexp file="${source.dir}/com/todoroo/astrid/billing/BillingConstants.java"
match="PUB_KEY_REPLACE_CHAR = .*"
replace="PUB_KEY_REPLACE_CHAR = &#39;${apikey.googleplay.replacechar}&#39;;" />
<replaceregexp file="${source.dir}/com/todoroo/astrid/billing/BillingConstants.java"
match="PUB_KEY_OBFUSCATED = .*"
replace="PUB_KEY_OBFUSCATED = &quot;${apikey.googleplay.pubkey}&quot;;" />
@ -172,11 +172,11 @@
replace="API_SECRET = &quot;${apikey.analytics.lite.secret}&quot;;" />
</target>
<target name="updatekeys-pre" if="pre.astrid" description="use pre.astrid.com">
<target name="updatekeys-pre" if="pre.astrid" description="use pre.astrid-dev.com">
<property file="${apikey.keyfile}" />
<replaceregexp file="${source.dir}/com/todoroo/astrid/actfm/sync/ActFmInvoker.java"
match="URL = .*"
replace="URL = &quot;//pre.astrid.com/api/&quot;;" />
replace="URL = &quot;//pre.astrid-dev.com/api/&quot;;" />
</target>
<!-- update api keys that require release signing -->
@ -185,9 +185,9 @@
<property file="${apikey.keyfile}" />
<replaceregexp file="${source.dir}/com/todoroo/astrid/actfm/ActFmLoginActivity.java"
match="APP_ID = .*"
replace="APP_ID = &quot;${apikey.facebook.id}&quot;;" />
replace="APP_ID = &quot;${apikey.facebook.id}&quot;;" />
</target>
<target name="-release-prompt-for-password" description="override to set signature">
<property file="${signjar.passfile}" /> <echo message="${signjar.passfile}" />
@ -201,14 +201,14 @@
<target name="update-market-strategy" if="custom.market.strategy">
<echo message="Changing market strategy to ${custom.market.strategy}" />
<replace token="market://" value="disabled://"
<replace token="market://" value="disabled://"
dir="${source.dir}" />
<replaceregexp file="${source.dir}/com/todoroo/astrid/utility/Constants.java"
match="AndroidMarketStrategy"
replace="${custom.market.strategy}" />
</target>
<target name="obfuscate" depends="-set-debug-files, -set-debug-mode, nodeps, -build-setup,
<target name="obfuscate" depends="-set-debug-files, -set-debug-mode, nodeps, -build-setup,
-set-release-mode, -release-obfuscation-check, -obfuscate" />
<target name="dex" depends="obfuscate, -dex" />
@ -234,14 +234,14 @@
<!-- build lite release package with updated version name -->
<target name="release-lite" depends="clean, set-lite-property, release" />
<target name="debug-lite" depends="clean, set-lite-property, debug" />
<target name="set-lite-property">
<property name="lite.enabled" value="true" />
<subant target="setup-lite">
<fileset file="../api/build.xml"/>
</subant>
</target>
<target name="setup-lite" if="lite.enabled">
<copy file="AndroidManifest.xml" tofile="AndroidManifest_old.xml" />
<replaceregexp file="${source.dir}/com/todoroo/astrid/utility/Constants.java"
@ -300,14 +300,14 @@
replace="ASTRID_DIR = &quot;/astridlite&quot;;"
/>
<move file="${source.dir}/com/timsu/astrid" tofile="${source.dir}/com/todoroo/astridlite" />
<copy todir="res_old">
<fileset dir="res"/>
</copy>
<replace dir="res" token="com.timsu.astrid" value="com.todoroo.astridlite"/>
<replace dir="${source.dir}" token="com.timsu.astrid" value="com.todoroo.astridlite"/>
<replaceregexp match="&gt;(.*\s)task(.*)"
replace="&gt;\1to-do\2"
flags="g">
@ -333,7 +333,7 @@
flags="g"
/>
</target>
<target name="teardown-lite" if="lite.enabled">
<delete dir="res" />
<move file="res_old" tofile="res"/>
@ -342,7 +342,7 @@
<fileset file="../api/build.xml"/>
</subant>
</target>
<!-- build custom unsigned package with updated version name -->
<target name="unsigned-custom" depends="clean">
<fail message="need to set custom.version.name">
@ -458,7 +458,7 @@
location="../release/${ant.project.name}-${manifest.version.code}-${manifest.version.name}-release.apk" />
</else>
</if>
<zipalign-helper in.package="${out.unaligned.file}"
out.package="${out.final.file}" />
<copy file="${out.final.file}" tofile="${out.release.file}" />

Loading…
Cancel
Save