Skip to content

Instantly share code, notes, and snippets.

@dschulz
Created April 25, 2016 03:11
Show Gist options
  • Save dschulz/ac58f7eeace987bf7d1641e7989f8e45 to your computer and use it in GitHub Desktop.
Save dschulz/ac58f7eeace987bf7d1641e7989f8e45 to your computer and use it in GitHub Desktop.
Profile para bash para ejecutar minicom
# ~/.profile: executed by the command interpreter for login shells.
# This file is not read by bash(1), if ~/.bash_profile or ~/.bash_login
# exists.
# see /usr/share/doc/bash/examples/startup-files for examples.
# the files are located in the bash-doc package.
# the default umask is set in /etc/profile; for setting the umask
# for ssh logins, install and configure the libpam-umask package.
#umask 022
# if running bash
if [ -n "$BASH_VERSION" ]; then
# include .bashrc if it exists
if [ -f "$HOME/.bashrc" ]; then
. "$HOME/.bashrc"
fi
fi
# set PATH so it includes user's private bin if it exists
if [ -d "$HOME/bin" ] ; then
PATH="$HOME/bin:$PATH"
fi
function ayuda(){
cat<<EOT
_____________________________________________________
Para iniciar la consola en el router cisco, ejecuta
minicom cisco
Para terminar la sesión minicom presiona
CONTROL + a
y luego
x
Diego
_____________________________________________________
EOT
}
ayuda
read -p "Conectar ahora? (s)" -n1 SINO
case $SINO in
s|S)
echo -e "\nEjecutando minicom..."
minicom cisco
echo -e "\n\nFinalizado."
ayuda
;;
*)
echo -e "\nOk"
;;
esac
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment