Skip to content

Instantly share code, notes, and snippets.

@rosen-vladimirov
Last active January 4, 2016 06:33
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save rosen-vladimirov/f9d9919ba9a413679af7 to your computer and use it in GitHub Desktop.
Save rosen-vladimirov/f9d9919ba9a413679af7 to your computer and use it in GitHub Desktop.
Sample application using mobile-cli-lib
var common = require("mobile-cli-lib");
common.fs.getFileSize("D:\\Work\\t.txt")
.then(function (result) {
console.log("File size is: " + result);
return result;
}, function (err) {
console.log("Error happened:");
console.log(err);
});
{
"name": "sample_mobile_cli_lib_app",
"version": "0.0.1",
"description": "This application shows how to use mobile-cli-lib as a separate npm package.",
"main": "index.js",
"dependencies": {
"mobile-cli-lib": "0.4.0"
},
"keywords": [
"mobile-cli-lib",
"node",
"npm",
"test",
"app"
],
"author": "Rosen Vladimirov <rossen_vl@abv.bg>",
"license": "ISC"
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment