Adding small tweaks to cnssh and cnsftp

This commit is contained in:
David Thurstenson 2019-12-12 14:16:33 -06:00
parent f3176367f1
commit 7741b91ce5
2 changed files with 4 additions and 3 deletions

View File

@ -1,5 +1,4 @@
cnsftp() { cnsftp() {
# sshpass -p "" ssh Crestron@192.168.0.51
local uname="Crestron" local uname="Crestron"
local pass="" local pass=""
local cmd="$@" local cmd="$@"
@ -8,6 +7,7 @@ cnsftp() {
-o StrictHostKeyChecking=no\ -o StrictHostKeyChecking=no\
-o GlobalKnownHostsFile=/dev/null\ -o GlobalKnownHostsFile=/dev/null\
-o UserKnownHostsFile=/dev/null\ -o UserKnownHostsFile=/dev/null\
-o LogLevel=ERROR\
-o User="$uname" \ -o User="$uname" \
"$cmd" "$cmd"
} }

View File

@ -1,6 +1,5 @@
cnssh() { cnssh() {
# Usage: cnssh <ip address> [command] # Usage: cnssh <ip address> [command]
# sshpass -p "" ssh Crestron@192.168.0.51
local uname="Crestron" local uname="Crestron"
local pass="" local pass=""
local addr="$1" local addr="$1"
@ -11,5 +10,7 @@ cnssh() {
-o StrictHostKeyChecking=no\ -o StrictHostKeyChecking=no\
-o GlobalKnownHostsFile=/dev/null\ -o GlobalKnownHostsFile=/dev/null\
-o UserKnownHostsFile=/dev/null\ -o UserKnownHostsFile=/dev/null\
"$uname"@"$addr" "$cmd" -o LogLevel=ERROR\
-o User="$uname"\
"$addr" "$cmd"
} }