OpenSDE Framework (without history before r20070)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

51 lines
1.6 KiB

  1. #!/bin/bash
  2. # --- SDE-COPYRIGHT-NOTE-BEGIN ---
  3. # This copyright note is auto-generated by ./scripts/Create-CopyPatch.
  4. #
  5. # Filename: scripts/Create-ParaStatus
  6. # Copyright (C) 2006 The OpenSDE Project
  7. # Copyright (C) 2004 - 2006 The T2 SDE Project
  8. # Copyright (C) 1998 - 2003 Clifford Wolf
  9. #
  10. # More information can be found in the files COPYING and README.
  11. #
  12. # This program is free software; you can redistribute it and/or modify
  13. # it under the terms of the GNU General Public License as published by
  14. # the Free Software Foundation; version 2 of the License. A copy of the
  15. # GNU General Public License can be found in the file COPYING.
  16. # --- SDE-COPYRIGHT-NOTE-END ---
  17. config=default
  18. while [ "$1" ] ; do
  19. case "$1" in
  20. -cfg) config=$2 ; shift ; shift ;;
  21. *) echo "Usage: $0 [ -cfg config ]" ; exit 1 ;;
  22. esac
  23. done
  24. . lib/parse-config
  25. qdir="$base/build/$SDECFG_ID/TOOLCHAIN/queue"
  26. if [ ! -d $qdir ] ; then
  27. echo
  28. echo "$qdir:"
  29. echo "Queue not found! Please start 'Build-Target -cfg $config'"
  30. echo "first on the master node ..."
  31. echo
  32. exit 1
  33. fi
  34. date '+%H:%M %Y-%m-%d:%t--- current status ---' | expand -t20
  35. cat $qdir/*.stat $qdir/*.lock 2> /dev/null | expand -t30
  36. if [ -f $qdir/queue.txt ] ; then
  37. while read line ; do
  38. set $line ; cat $qdir/$1-$6.todo 2> /dev/null
  39. done < $qdir/queue.txt | expand -t30
  40. else
  41. echo -e 'Queue file not found!\tDisplaying' \
  42. 'all prepared jobs:' | expand -t30
  43. cat $qdir/*.todo 2> /dev/null | sort -n -r -k9 | expand -t30
  44. fi
  45. date '+%H:%M %Y-%m-%d:%t----------------------' | expand -t20