Implementation of aapt in nodejs
npm install aaptjs3- in npm
``bash`
npm install aaptjs3 --save
- in yarn
`bash`
yarn add aaptjs3
`js
const aapt = require('aaptjs3');
aapt.list('/path/to/your/ExampleApp.apk', ['-a'])
.then (data => {
// Your implementation
})
.catch ((err) => {
// Your implementation
});
`
typescript
interface ExecResult {
stdout: string,
stderr: string,
}interface PackageInfo {
package: string,
version: string,
name: string,
icon: string,
}
export function aapt(commanArgs: string[], maxBuffer?: number): Promise;
export function list(apkPath: string, args?: Array): Promise;
export function dump(apkPath: string, value: string): Promise;
export function packageCmd(filePath: string, command: string): Promise;
export function remove(filePath: string, files: string[]): Promise;
export function add(filePath: string, files: string[]): Promise;
export function crunch(resource: string[], outputFolder: string): Promise;
export function singleCrunch(inputFile: string, outputFile: string): Promise;
export function getApkInfo(filePath: string): Promise;
``