#!/bin/bash

function check_okay {
	if [ $? -ne 0 ]
	then
		exit 1
	fi
}

function do_one {
	cd $1
	check_okay
	echo "clean" $1
	./clean
	rm -f LOGS/*
	rm -f photos/*
	rm -f out.txt
  if [ -r star_history/history_out ]
  then
  	rm -f star_history/history_out/*
  fi
  if [ -r star_profile/profiles_out ]
  then
  	rm -f star_profile/profiles_out/*
  fi
	cd ..
}

source do1_test_source
