#/bin/bash
####################################################################### 
# Name: feed_tux.sh
#
# Requirements: None
#
# Description: Simple script to illustrate 'if' conditional
# 
# Usage: feed_tux.sh animal food
#
# Notes: Modified for presentation at local lug meeting
# This script lets you present different menus to Tux.  He will only
# be happy when given a fish.
#
# Author: Unknown, found at
# http://tldp.org/LDP/Bash-Beginners-Guide/html/index.html
#
# License: GPL
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program.  If not, see <http://www.gnu.org/licenses/>.
#
####################################################################### 


if [ ! "$#" -eq 2 ]; then
echo "Usage: feed_tux.sh animal food"
exit 1
fi

animal=$1
food=$2

if [ "$animal" = "penguin" ]; then
	if [ "$food" = "fish" ]; then
	echo "Hmmmmmm fish... Tux happy!"
	else
	echo "Tux doesn't want $food, tux wants fish!"
	fi
else echo "Do ${animal}'s even eat ${food}?"
fi


