title: Ionic/Cordova: Add intent-filter using config.xml
body: <p>I'm developing a mobile app using Ionic Framework (based on Cordova).</p>
  <p>In Android I register my app to open *.txt files.
  I do it adding intent-filter in platforms/android/AndroidManifest.xml and it works.
  But platform folder is in .gitignore: I want to do it using config.xml.</p>
  <p>I tried adding in config.xml:</p>
  <pre class="lang-html prettyprint-override"><code>     &lt;platform name=&quot;android&quot;&gt;
          &lt;config-file target=&quot;AndroidManifest.xml&quot; parent=&quot;/*/application/activity&quot;&gt;
            &lt;intent-filter&gt;&lt;!-- ... --&gt;&lt;/intent-filter&gt;
          &lt;/config-file&gt;
          &lt;!-- ... --&gt;
       &lt;/platform&gt;
  </code></pre>
  <p>And I tried also adding:</p>
  <pre class="lang-html prettyprint-override"><code>     &lt;platform name=&quot;android&quot;&gt;
          &lt;config-file target=&quot;AndroidManifest.xml&quot; parent=&quot;/manifest/application&quot;&gt;
            &lt;activity android:name=&quot;CordovaApp&quot;&gt; 
              &lt;intent-filter&gt;&lt;!-- ... --&gt;&lt;/intent-filter&gt;
            &lt;/activity&gt;
          &lt;/config-file&gt;
          &lt;!-- ... --&gt;
       &lt;/platform&gt;
  </code></pre>
  <p>Then I tried to update AndroidManifest launching</p>
  <pre><code>ionic prepare
  </code></pre>
  <p>Or also:</p>
  <pre><code>ionic remove platform android &amp;&amp; ionic add platform android
  </code></pre>
  <p>But AndroidManifest.xml is always unchanged.
  What am I doing wrong?</p>
  <p>I'm using Ionic 1.3.2 and Cordova 4.2.0.</p>
  <p><strong>Edit</strong>
  Here the entire config.xml:</p>
  <pre class="lang-xml prettyprint-override"><code>    &lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot; standalone=&quot;yes&quot;?&gt;
      &lt;widget id=&quot;com.ionicframework.myapp551932&quot; version=&quot;0.0.1&quot; xmlns=&quot;http://www.w3.org/ns/widgets&quot; xmlns:cdv=&quot;http://cordova.apache.org/ns/1.0&quot; xmlns:android=&quot;http://schemas.android.com/apk/res/android&quot;&gt;
        &lt;name&gt;MyApp&lt;/name&gt;
        &lt;description&gt;
              myApp
          &lt;/description&gt;
        &lt;author email=&quot;xxx@yyy.it&quot; href=&quot;http://www.example.com/&quot;&gt;
            A Team
          &lt;/author&gt;
        &lt;content src=&quot;index.html&quot;/&gt;
        &lt;access origin=&quot;*&quot;/&gt;
        &lt;preference name=&quot;webviewbounce&quot; value=&quot;false&quot;/&gt;
        &lt;preference name=&quot;UIWebViewBounce&quot; value=&quot;false&quot;/&gt;
        &lt;preference name=&quot;DisallowOverscroll&quot; value=&quot;true&quot;/&gt;
        &lt;preference name=&quot;BackupWebStorage&quot; value=&quot;none&quot;/&gt;
        &lt;preference name=&quot;SplashScreen&quot; value=&quot;screen&quot;/&gt;
        &lt;preference name=&quot;SplashScreenDelay&quot; value=&quot;3000&quot;/&gt;
        &lt;feature name=&quot;StatusBar&quot;&gt;
          &lt;param name=&quot;ios-package&quot; value=&quot;CDVStatusBar&quot; onload=&quot;true&quot;/&gt;
        &lt;/feature&gt;
        &lt;platform name=&quot;android&quot;&gt;
          &lt;config-file target=&quot;AndroidManifest.xml&quot; parent=&quot;/manifest/application/activity&quot;&gt;
            &lt;intent-filter&gt;
              &lt;action android:name=&quot;android.intent.action.VIEW&quot; /&gt;
              &lt;category android:name=&quot;android.intent.category.DEFAULT&quot; /&gt;
              &lt;category android:name=&quot;android.intent.category.BROWSABLE&quot; /&gt;
              &lt;data android:scheme=&quot;file&quot; /&gt;
              &lt;data android:mimeType=&quot;*/*&quot; /&gt;
              &lt;data android:pathPattern=&quot;.*\\.txt&quot; /&gt;
              &lt;data android:host=&quot;*&quot; /&gt;
            &lt;/intent-filter&gt;
            &lt;intent-filter&gt;
              &lt;action android:name=&quot;android.intent.action.VIEW&quot; /&gt;
              &lt;category android:name=&quot;android.intent.category.DEFAULT&quot; /&gt;
              &lt;data android:scheme=&quot;content&quot; /&gt;
              &lt;data android:pathPattern=&quot;.*\\.txt&quot; /&gt;
              &lt;data android:mimeType=&quot;*/*&quot; /&gt;
            &lt;/intent-filter&gt;
          &lt;/config-file&gt;
          &lt;icon src=&quot;resources/android/icon/drawable-ldpi-icon.png&quot; density=&quot;ldpi&quot;/&gt;
          &lt;icon src=&quot;resources/android/icon/drawable-mdpi-icon.png&quot; density=&quot;mdpi&quot;/&gt;
          &lt;icon src=&quot;resources/android/icon/drawable-hdpi-icon.png&quot; density=&quot;hdpi&quot;/&gt;
          &lt;icon src=&quot;resources/android/icon/drawable-xhdpi-icon.png&quot; density=&quot;xhdpi&quot;/&gt;
          &lt;icon src=&quot;resources/android/icon/drawable-xxhdpi-icon.png&quot; density=&quot;xxhdpi&quot;/&gt;
          &lt;icon src=&quot;resources/android/icon/drawable-xxxhdpi-icon.png&quot; density=&quot;xxxhdpi&quot;/&gt;
          &lt;splash src=&quot;resources/android/splash/drawable-land-ldpi-screen.png&quot; density=&quot;land-ldpi&quot;/&gt;
          &lt;splash src=&quot;resources/android/splash/drawable-land-mdpi-screen.png&quot; density=&quot;land-mdpi&quot;/&gt;
          &lt;splash src=&quot;resources/android/splash/drawable-land-hdpi-screen.png&quot; density=&quot;land-hdpi&quot;/&gt;
          &lt;splash src=&quot;resources/android/splash/drawable-land-xhdpi-screen.png&quot; density=&quot;land-xhdpi&quot;/&gt;
          &lt;splash src=&quot;resources/android/splash/drawable-land-xxhdpi-screen.png&quot; density=&quot;land-xxhdpi&quot;/&gt;
          &lt;splash src=&quot;resources/android/splash/drawable-land-xxxhdpi-screen.png&quot; density=&quot;land-xxxhdpi&quot;/&gt;
          &lt;splash src=&quot;resources/android/splash/drawable-port-ldpi-screen.png&quot; density=&quot;port-ldpi&quot;/&gt;
          &lt;splash src=&quot;resources/android/splash/drawable-port-mdpi-screen.png&quot; density=&quot;port-mdpi&quot;/&gt;
          &lt;splash src=&quot;resources/android/splash/drawable-port-hdpi-screen.png&quot; density=&quot;port-hdpi&quot;/&gt;
          &lt;splash src=&quot;resources/android/splash/drawable-port-xhdpi-screen.png&quot; density=&quot;port-xhdpi&quot;/&gt;
          &lt;splash src=&quot;resources/android/splash/drawable-port-xxhdpi-screen.png&quot; density=&quot;port-xxhdpi&quot;/&gt;
          &lt;splash src=&quot;resources/android/splash/drawable-port-xxxhdpi-screen.png&quot; density=&quot;port-xxxhdpi&quot;/&gt;
        &lt;/platform&gt;
        &lt;icon src=&quot;resources/android/icon/drawable-xhdpi-icon.png&quot;/&gt;
      &lt;/widget&gt;
  </code></pre>