Move facebook app id to keys.xml file so we can reference it from the manifest

pull/14/head
Sam Bosley 13 years ago
parent 2b3c9ef3b3
commit ce37aa607b

@ -92,6 +92,7 @@
android:hardwareAccelerated="false" android:hardwareAccelerated="false"
android:manageSpaceActivity="com.todoroo.astrid.core.OldTaskPreferences"> android:manageSpaceActivity="com.todoroo.astrid.core.OldTaskPreferences">
<meta-data android:name="com.facebook.sdk.ApplicationId" android:value="@string/fb_app_id"/>
<!-- ====================================================== Activities = --> <!-- ====================================================== Activities = -->
<!-- Activity that displays task list --> <!-- Activity that displays task list -->

@ -70,7 +70,7 @@
<taskdef name="proguard" classname="proguard.ant.ProGuardTask" classpath="${proguard.jar}" /> <taskdef name="proguard" classname="proguard.ant.ProGuardTask" classpath="${proguard.jar}" />
</target> </target>
<target name="-post-astrid-build" depends="teardown-lite" /> <target name="-post-astrid-build" depends="teardown-lite, teardown" />
<target name="copy-sources"> <target name="copy-sources">
<delete dir="${source.dir}" /> <delete dir="${source.dir}" />
@ -183,9 +183,9 @@
<target name="updatekeys-release" if="build.is.mode.release" depends="updatekeys-pre" <target name="updatekeys-release" if="build.is.mode.release" depends="updatekeys-pre"
description="update release-only api key values"> description="update release-only api key values">
<property file="${apikey.keyfile}" /> <property file="${apikey.keyfile}" />
<replaceregexp file="${source.dir}/com/todoroo/astrid/actfm/ActFmLoginActivity.java" <replaceregexp file="res/values/keys.xml"
match="APP_ID = .*" match="fb_app_id&quot;&gt;.*&lt;"
replace="APP_ID = &quot;${apikey.facebook.id}&quot;;" /> replace="fb_app_id&quot;&gt;${apikey.facebook.id}&lt;" />
</target> </target>
@ -343,6 +343,12 @@
</subant> </subant>
</target> </target>
<target name="teardown">
<replaceregexp file="res/values/keys.xml"
match="fb_app_id&quot;&gt;.*&lt;"
replace="fb_app_id&quot;&gt;183862944961271&lt;" />
</target>
<!-- build custom unsigned package with updated version name --> <!-- build custom unsigned package with updated version name -->
<target name="unsigned-custom" depends="clean"> <target name="unsigned-custom" depends="clean">
<fail message="need to set custom.version.name"> <fail message="need to set custom.version.name">

@ -95,8 +95,6 @@ import com.todoroo.astrid.service.TaskService;
*/ */
public class ActFmLoginActivity extends SherlockFragmentActivity { public class ActFmLoginActivity extends SherlockFragmentActivity {
public static final String APP_ID = "183862944961271"; //$NON-NLS-1$
@Autowired @Autowired
protected ExceptionService exceptionService; protected ExceptionService exceptionService;
@Autowired @Autowired

@ -5,6 +5,8 @@
--> -->
<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2"> <resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
<string name="fb_app_id">183862944961271</string>
<!-- ======================================================== REMINDERS == --> <!-- ======================================================== REMINDERS == -->
<!-- whether reminders should appear at all --> <!-- whether reminders should appear at all -->

Loading…
Cancel
Save