title: Bash if statement not working properly
body: <p>I have a bash statement to test a command line argument. If the argument passed to the script is "clean", then the script removes all .o files. Otherwise, it builds a program. However, not matter what is passed (if anything), the script still thinks that the argument "clean" is being passed.</p>
  
  <pre><code>#!/bin/bash
  if test "`whoami`" != "root" ; then
      echo "You must be logged in as root to build (for loopback mounting)"
      echo "Enter 'su' or 'sudo bash' to switch to root"
      exit
  fi
  ARG=$1
  if [ $ARG == "clean" ] ; then
      echo "&gt;&gt;&gt; cleaning up object files..."
      rm -r src/*.o
      echo "&gt;&gt;&gt; done. "
      echo "&gt;&gt;&gt; Press enter to continue..."
      read
  else
      #Builds program
  fi
  </code></pre>