made changeport work
This commit is contained in:
@@ -1 +1,2 @@
|
|||||||
test-scratch.sh
|
test-scratch.sh
|
||||||
|
notes.txt
|
||||||
+13
-2
@@ -1,3 +1,4 @@
|
|||||||
|
subprocess() {
|
||||||
echo "\nChanging ESPPORT\n"
|
echo "\nChanging ESPPORT\n"
|
||||||
echo "TTY devices found in dmesg:"
|
echo "TTY devices found in dmesg:"
|
||||||
COUNTER=0
|
COUNTER=0
|
||||||
@@ -10,7 +11,17 @@ done
|
|||||||
|
|
||||||
echo "\nEnter TTY Number You'd Like:"
|
echo "\nEnter TTY Number You'd Like:"
|
||||||
read tty
|
read tty
|
||||||
ttyselect=$devarr[(($tty+1))]
|
|
||||||
export ESPPORT="${ttyselect}"
|
sel=$tty+1
|
||||||
|
eval "$1=$devarr[$sel]"
|
||||||
|
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
|
ret=''
|
||||||
|
subprocess ret
|
||||||
|
|
||||||
|
export ESPPORT=$ret
|
||||||
|
|
||||||
echo "\nESPPORT set to ${ESPPORT}\n"
|
echo "\nESPPORT set to ${ESPPORT}\n"
|
||||||
echo "\nall done :3\n"
|
echo "\nall done :3\n"
|
||||||
Reference in New Issue
Block a user