![команда для открытия android studio](https://rvso.com/image/1127623/%D0%BA%D0%BE%D0%BC%D0%B0%D0%BD%D0%B4%D0%B0%20%D0%B4%D0%BB%D1%8F%20%D0%BE%D1%82%D0%BA%D1%80%D1%8B%D1%82%D0%B8%D1%8F%20android%20studio.png)
Недавно я установил easystroke на свою систему Ubuntu 14.04 LTS. Хочу добавить горячую клавишу stroke для того же самого. Можете ли вы сказать мне, какую команду использовать? Расположение android studio
/home/antony/Documents/Android Studio Installation Files/android-studio/bin/studio.sh
для других приложений, таких как Firefox, которые я использую
wmctrl -a Firefox || firefox
но это не работает для android studio
также
xdg-open of /home/....
открывает файл bash в текстовом редакторе вместо терминала.
Пожалуйста, помогите мне, ребята.
решение1
С помощью этой команды:
wmctrl -a "Android Studio" || "/home/antony/Documents/Android Studio Installation Files/android-studio/bin/studio.sh"
Используйте полный путь в двойных кавычках.
отman wmctrl
-a <WIN>
Switch to the desktop containing the window <WIN>, raise the window, and give it
focus.
<WIN> This argument specifies a window that is the target of an action. By default the
argument is treated as if were a string, and windows are examined until one is
found with a title the contains the specified string as a substring. The substring
matching is done in a case insensitive manner. The -F option may be used to force
exact, case sensitive title matching. The option -i may be used to interpret the
window target as a numeric window identity instead of a string.
решение2
Попробуй это:
xdotool type "sh '/home/antony/Documents/Android Studio Installation Files/android-studio/bin/studio.sh'" ; xdotool key KP_Enter
если не работает, попробуйте это:
wmctrl -a "Android Studio" || "/home/antony/Documents/Android Studio Installation Files/android-studio/bin/studio.sh"