[英]Android: adb pull file on desktop
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.但是此命令会在 adb 所在的 platform-tools 文件夹中创建一个文件夹 Users/admin/Desktop。 How to pull file to my desktop?如何将文件拉到我的桌面?
Use a fully-qualified path to the desktop (eg, /home/mmurphy/Desktop
).使用完全限定的桌面路径(例如, /home/mmurphy/Desktop
)。
Example: adb pull sdcard/log.txt /home/mmurphy/Desktop
示例: adb pull sdcard/log.txt /home/mmurphy/Desktop
Judging by the desktop folder location you are using Windows.根据您使用 Windows 的桌面文件夹位置判断。 The command in Windows would be: Windows 中的命令是:
adb pull /sdcard/log.txt %USERPROFILE%\Desktop\
On Windows, start up Command Prompt (cmd.exe) or PowerShell (powershell.exe).在 Windows 上,启动命令提示符(cmd.exe) 或PowerShell (powershell.exe)。 To do this quickly, open a Run Command window by pressing Windows Key + R .要快速执行此操作,请按Windows 键 + R打开运行命令窗口。 In the Run Command window, type "cmd.exe" to launch Command Prompt;在“运行命令”窗口中,键入“cmd.exe”以启动命令提示符; However, to start PowerShell instead, then type "powershell".但是,要改为启动 PowerShell,请键入“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:如果您使用 USB 电缆将 Android 设备连接到计算机,则需要通过输入以下命令来检查您的设备是否正在与adb
通信:
# adb devices -l
Next, pull (copy) the file from your Android device over to Windows.接下来,将文件从您的 Android 设备拉(复制)到 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
注意需要root比:
adb root
adb pull /data/data/com.google.android.apps.nexuslauncher/databases/launcher.db launcher.db
做 adb pull \\sdcard\\log.txt C:Users\\admin\\Desktop
List item项目清单
Use following command to pull data from ADB使用以下命令从 ADB 中提取数据
adb pull data/user/0/project package name/files/.local/share/dbname C:\Users\vijayalaxmi.k adb pull data/user/0/project package name/files/.local/share/dbname C:\Users\vijayalaxmi.k
data/user/0/project package name/files/.local/share/dbname this path you will get when you debug application. data/user/0/project package name/files/.local/share/dbname 调试应用程序时将获得此路径。 ie database path即数据库路径
project package name example => com.example项目 package 名称示例 => com.example
instead of C:\Users\vijayalaxmi.k user your own path where you want to save your file.而不是 C:\Users\vijayalaxmi.k 使用您自己的路径来保存文件。 for example, c:\documents例如,c:\documents
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.