Android: adb pull file on desktop

AndroidAdb

Android Problem Overview


Trying to copy file from device to desktop, here is a command:

adb pull sdcard/log.txt Users/admin/Desktop

But this command creates a folder Users/admin/Desktop inside platform-tools folder where adb is located. How to pull file to my desktop ?

Android Solutions


Solution 1 - Android

Use a fully-qualified path to the desktop (e.g., /home/mmurphy/Desktop).

Example: adb pull sdcard/log.txt /home/mmurphy/Desktop

Solution 2 - Android

Judging by the desktop folder location you are using Windows. The command in Windows would be:

adb pull /sdcard/log.txt %USERPROFILE%\Desktop\

Solution 3 - Android

Be root, Define file on device and define new filename.

adb root
adb pull /data/data/.../databases/launcher.db launcher.db

Solution 4 - Android

On Windows, start up Command Prompt (cmd.exe) or PowerShell (powershell.exe). To do this quickly, open a Run Command window by pressing Windows Key + R. In the Run Command window, type "cmd.exe" to launch Command Prompt; However, to start PowerShell instead, then type "powershell". If you are connecting your Android device to your computer using a USB cable, then you will need to check whether your device is communicating with adb by entering the command below:

# adb devices -l  

Next, pull (copy) the file from your Android device over to Windows. This can be accomplished by entering the following command:

# adb pull /sdcard/log.txt %HOME%\Desktop\log.txt  

Optionally, you may enter this command instead:

# adb pull /sdcard/log.txt C:\Users\admin\Desktop\log.txt 

Solution 5 - Android

do adb pull \sdcard\log.txt C:Users\admin\Desktop

Attributions

All content for this solution is sourced from the original question on Stackoverflow.

The content on this page is licensed under the Attribution-ShareAlike 4.0 International (CC BY-SA 4.0) license.

Content TypeOriginal AuthorOriginal Content on Stackoverflow
QuestionJimView Question on Stackoverflow
Solution 1 - AndroidCommonsWareView Answer on Stackoverflow
Solution 2 - AndroidAlex P.View Answer on Stackoverflow
Solution 3 - Androidniek tuytelView Answer on Stackoverflow
Solution 4 - AndroidDavid your friendView Answer on Stackoverflow
Solution 5 - AndroidKirtap LlahsramView Answer on Stackoverflow