old_contents: #!/usr/bin/env python
  
  import os
  import sys
  from subprocess import Popen, STDOUT, PIPE
  
  # Check for arguments
  if len(sys.argv) > 1:
      folders = []
      for i in range(len(sys.argv)):
          if i == 0: continue
          folders.append((sys.argv[i],' ',' '))
  else:
      folders = os.walk('.')
  
  # Loop around directories
  for root, dirs, files in folders:
  
    # Delete first two characters
    if root[0:2] == './':
      root = root[2:]
  
    # Don't continue if not prefixed by test
    if root[0:4] != 'test':
      continue
   
    # Go into that directory
    os.chdir(root)
    pwd = os.path.abspath(os.path.dirname('settings.xml'))
    os.putenv('PWD', pwd)
  
    # Run openmc
    proc = Popen(['../../src/openmc'])
    returncode = proc.wait()
  
    # Process results
    os.system('python results.py') 
    os.system('mv results_test.dat results_true.dat')
    os.system('rm -f *.binary *.out')
  
    # Go back a directory
    os.chdir('..')
  
new_contents: #!/usr/bin/env python
  
  import os
  import sys
  from subprocess import Popen, STDOUT, PIPE
  
  class bcolors:
      HEADER = '\033[95m'
      OKBLUE = '\033[94m'
      OKGREEN = '\033[92m'
      WARNING = '\033[93m'
      FAIL = '\033[91m'
      ENDC = '\033[0m'
  
      def disable(self):
          self.HEADER = ''
          self.OKBLUE = ''
          self.OKGREEN = ''
          self.WARNING = ''
          self.FAIL = ''
          self.ENDC = ''
  
  # Check for arguments
  if len(sys.argv) > 1:
      folders = []
      for i in range(len(sys.argv)):
          if i == 0: continue
          folders.append((sys.argv[i],' ',' '))
  else:
      folders = os.walk('.')
  
  # Loop around directories
  for root, dirs, files in folders:
  
    # Delete first two characters
    if root[0:2] == './':
      root = root[2:]
  
    # Don't continue if not prefixed by test
    if root[0:4] != 'test':
      continue
  
    # Skip test compile or plot
    if root == 'test_compile' or root.find('plot') != -1:
        continue
   
    # Go into that directory
    os.chdir(root)
    pwd = os.path.abspath(os.path.dirname('settings.xml'))
    os.putenv('PWD', pwd)
  
    # Print status to screen
    sys.stdout.write(root+'... ')
  
    # Run openmc
    proc = Popen(['../../src/openmc'], stderr=STDOUT, stdout=PIPE)
    returncode = proc.wait()
    if returncode == 0:
      sys.stdout.write(bcolors.OKGREEN + "OK" + bcolors.ENDC + "\n")
    else:
      sys.stdout.write(bcolors.FAIL + "ERROR" + bcolors.ENDC + "\n")
  
    # Process results
    os.system('python results.py') 
    os.system('mv results_test.dat results_true.dat')
    os.system('rm -f *.binary *.out')
  
    # Go back a directory
    os.chdir('..')
  
subject: update script now prints when each folder is updated