#!/usr/bin/tcsh -f # set echo verbose # If debugging, remove the # at the start of this line # Gives a warning if there is a ..._FAILED file on your Desktop. Such # files indicate backups that have failed. You can also add your own # noninteractive and interactive commands to this script that you want # executed at login time. # See http://www.eng.fsu.edu/~dommelen/backup/index.html#warning2 or # http://www.dommelen.net/backup/index.html#warning2 for # installation instructions. # go to the home folder cd ########################################################################## # Noninteractive commands to be executed: # End of noninteractive commands ########################################################################### # If you *always* need to perform interactive commands on login, then # remove the # from the start of the next line: #goto do_startup2 # If you *sometimes* need to perform interactive commands on login, # then add conditional goto do_startup2 commands below this line: # Produce an interactive warning if there are failed backup notices cd if !(-d Desktop) goto endwarn if (`find Desktop -name '*_FAILED' | wc -l` == 0) goto endwarn goto do_startup2 endwarn: # if we did not jump to do_startup2, we are done exit 0 # we need to set up the interactive commands now do_startup2: # check setup and move into desktop cd cd Desktop if (`pwd` != "$HOME/Desktop") exit 1 if !(-d ../Desktop_saved) exit 1 if (-f startup2.desktop) mv startup2.desktop ../Desktop_saved if !(-f ../Desktop_saved/startup2.desktop) exit 1 # if there are files on the desktop, move them out of the way for now if (`ls -1 | wc -l` != 0) then mv * ../Desktop_saved/ endif # move the Run Me icon on the cleaned-up desktop mv ../Desktop_saved/startup2.desktop .