linux - Simulating Enter in Bash Script on CentOS 6 Minimal -
right using:
echo -ne '\n' | alternatives --config java
for
enter keep current selection, or type selection number:
i know there many ways this. looking correct way perform action. don't know if i'm doing right.
probably use less interactive.
alternatives --set java /your/favorite/version
should work. or can use 'expect' command emulate user input.
Comments
Post a Comment