I have workprofile app installed, and the location of the data can be access programmatically using getExternalFilesDir("logs")
which, results in storage location as /storage/emulated/11/Android/data/com.example.workprofile/files/logs
.
I would like to know how to push data to logs folder and pull using adb
.
Let's assume you want to copy the file called
data.log
. The following commands will push the file into a temporary folderand then you can copy it into your app's private area:
If you want to pull the file you can do the opposite but you have to make sure that the file you want to copy already exists in the
/data/local/tmp
folder to workaround the permission deny issue (if the file does not exist).Hope this helps.