Skip to content

Android Asset Packaging Tool for Node.js allows you to view .apk archives

License

Notifications You must be signed in to change notification settings

baishiup/node-aapt

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

node-aapt npm version license Codacy Badge

Install

With npm do:

npm install node-aapt --save

Example

Using a callback:

const packageInfo = require('node-aapt');

packageInfo('/path/to/your/ExampleApp.apk', (err, data) => {
  if (err) {
    // something went wrong 
  } else {
    console.log(data);
  }
});

Using a promise:

const packageInfo = require('node-aapt');

packageInfo('/path/to/your/ExampleApp.apk')
  .then (data => {
    console.log(data)
  })
  .catch (err) {
    // something went wrong 
  }

In the console output you will see something like this:

{ packageName: 'com.example.app',
  versionCode: '12',
  versionName: '1.2.3' }  

API

packageInfo(path, callback)

path

Type: String

Path to your APK file.

callback

Type: function (err, data)

data

Type: Object

It contains the parsed data obtained from aapt tool.

License

MIT © Makarian Vladyslav

About

Android Asset Packaging Tool for Node.js allows you to view .apk archives

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • JavaScript 100.0%