0

我用这个答案来解决这个问题 -为开发设置设备(?????? 没有权限),它对我有帮助。但是存在以下问题 - 重新启动系统后我必须执行以下命令:

sudo service udev restart
sudo killall adb
sudo ~/android-sdk-linux/platform-tools/adb start-server

毕竟一切都好。但是我该如何解决呢?我不想每次重新启动系统后都执行它。

4

1 回答 1

0

首先打开终端进入gksudo gedit /etc/rc.local并修改文件如下图

#!/bin/sh -e
#
# rc.local
#
# This script is executed at the end of each multiuser runlevel.
# Make sure that the script will "exit 0" on success or any other
# value on error.
#
# In order to enable or disable this script just change the execution
# bits.
#
# By default this script does nothing.

PASSWORD='yourPasswordHere'

echo $PASSWORD | sudo -S service udev restart
echo $PASSWORD | sudo -S killall adb
echo $PASSWORD | sudo -S ~/android-sdk-linux/platform-tools/adb start-server

exit 0

adb devices现在重新启动系统后尝试。确保yourPasswordHere用您的登录密码替换。我没有测试过。希望这可以帮助。

于 2013-01-02T13:29:14.940 回答