cordova-plugin-shell-exec icon indicating copy to clipboard operation
cordova-plugin-shell-exec copied to clipboard

Can't make it work with with most commands

Open hvdwolf opened this issue 8 years ago • 1 comments

Hi,

When I use a command like 'uptime' or 'pwd' or ['uptime'] or ['pwd'], it simply works. If I use something like 'tar' I expect the normal output on how to use it, but I see nothing. No output at all. Commands like 'ls -l' or ['ls -l'] or ['ls', '-l'] or 'mkdir -p /sdcard/tmp' or ['mkdir -p /sdcard/tmp'] or ['mkdir', '-p', '/sdcard/JT'] or ['sh', '-c', 'mkdir -p /sdcard/tmp'] simply don't work.

What is wrong or what I do wrong?

Edit: Even though it is a shell command doing "things" and not the apk itself, I also added the following 2 lines to my Androidmanifest.xml and recompiled, signed and zip-aligned. <uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE"/> <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>

This didn't help either.

hvdwolf avatar Apr 14 '17 09:04 hvdwolf

try https://github.com/Poyser1911/cordova-plugin-shell-exec used in a app i'm making all cmds a executed as root tho, used ls and mk -p in project as well all works and cmds joined up with &&.

Poyser1911 avatar May 09 '17 17:05 Poyser1911