Reputation: 423
I'm currently using adb terminal to access my database files. However, I can only access the terminal using this:
./adb shell
I would like to switch from sh to bash as it is much more convenient for some shortcuts. How do I do that?
Upvotes: 2
Views: 5516
Reputation: 184955
Answered here
Found the proper & simple way from a Linux box:
adb shell -t bash -i
You logon directly via bash in interactive way.
To not having to remember this command all the times, I personally
use an alias, simply add this to your ~/.bashrc
on Linux box:
alias adb_shell='adb shell -t bash -i'
source ~/.bashrc
Then all is configured, simply run
adb_shell
and enjoy all bash
features like tab completion and anything. \o/
Upvotes: 1
Reputation: 2615
i dont think adb have bash options , if you type adb help , you will see options for shell and not for bash
shell:
shell [-e ESCAPE] [-n] [-Tt] [-x] [COMMAND...]
run remote shell command (interactive shell if no command given)
-e: choose escape character, or "none"; default '~'
-n: don't read from stdin
-T: disable PTY allocation
-t: force PTY allocation
-x: disable remote exit codes and stdout/stderr separation
emu COMMAND run emulator console command
May be if you can share, what specific difficulties you are facing in running the shortcut or command
However if you still wanted to use adb with bash , you can have a look on below link
https://android.stackexchange.com/questions/19315/how-to-set-bash-as-default-shell
Upvotes: 1