GithubHelp home page GithubHelp logo

ammt's Introduction

AMMT

Modify binary AndroidManifest.xml(ARSC)

  1. add attribute
<application android:debuggable="true" ...>
ammt -t attr -m insert -r application,package,debuggable,true AndroidManifest.xml AndroidManifest.xml_dump
  1. remove attribute
ammt -t attr -m remove -r application,allowBackup AndroidManifest.xml AndroidManifest.xml_dump
  1. add attribute
ammt -t attr -m modify -r application,package,debuggable,false AndroidManifest.xml AndroidManifest.xml_dump
  1. add tag
<recevier android:name="test.ABCReceiver" ...>
ammt -t tag -m insert -r receiver,test.ABCReceiver,exported:true,enabled:true AndroidManifest.xml AndroidManifest.xml_dump
  1. remove tag
ammt -t tag -m remove -r receiver test.ABCReceiver AndroidManifest.xml AndroidManifest.xml_dump

Building & Running

####1.maven

mvn install:install-file -Dfile=libs/AXMLEditor-1.0.jar -DgroupId=cn.wjdiankong -DartifactId=AXMLEditor -Dversion=1.0 -Dpackaging=jar

mvn package

java -jar target/ammt-1.0-jar-with-dependencies.jar -h
Usage: ammt OPTIONS
Options category 'misc':
  --[no]help [-h] (a boolean; default: "false")
    print usage
  --input [-i] (a string; default: "")
    input AndroidManifest.xml
  --mode [-m] (a string; default: "modify")
    insert|remove|modify
  --output [-o] (a string; default: "AndroidManifest_out.xml")
    output AndroidManifest.xml
  --resources [-r] (a string; default: "")
    seperated by ','(e.g., -t attr -m insert -r application,package,debuggable,
    true -i AndroidManifest.xml)
  --type [-t] (a string; default: "attr")
    tag|attr
  --[no]verbose [-v] (a boolean; default: "false")
    verbose mode

####2.bazel

bazel build //:ammt

./bazel-bin/ammt -h
Usage: ammt OPTIONS
Options category 'misc':
  --[no]help [-h] (a boolean; default: "false")
    print usage
  --input [-i] (a string; default: "")
    input AndroidManifest.xml
  --mode [-m] (a string; default: "modify")
    insert|remove|modify
  --output [-o] (a string; default: "AndroidManifest_out.xml")
    output AndroidManifest.xml
  --resources [-r] (a string; default: "")
    seperated by ','(e.g., -t attr -m insert -r application,package,debuggable,
    true -i AndroidManifest.xml)
  --type [-t] (a string; default: "attr")
    tag|attr
  --[no]verbose [-v] (a boolean; default: "false")
    verbose mode

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.