VirtualBox

source: vbox/trunk/src/VBox/Additions/3D/mesa/mesa-24.0.2/.gitlab-ci/bare-metal/expect-output.sh@ 103996

Last change on this file since 103996 was 103996, checked in by vboxsync, 13 months ago

Additions/3D/mesa: export mesa-24.0.2 to OSE. bugref:10606

  • Property svn:eol-style set to native
  • Property svn:executable set to *
File size: 491 bytes
Line 
1#!/bin/bash
2
3set -e
4
5STRINGS=$(mktemp)
6ERRORS=$(mktemp)
7
8trap 'rm $STRINGS; rm $ERRORS;' EXIT
9
10FILE=$1
11shift 1
12
13while getopts "f:e:" opt; do
14 case $opt in
15 f) echo "$OPTARG" >> "$STRINGS";;
16 e) echo "$OPTARG" >> "$STRINGS" ; echo "$OPTARG" >> "$ERRORS";;
17 *) exit
18 esac
19done
20shift $((OPTIND -1))
21
22echo "Waiting for $FILE to say one of following strings"
23cat "$STRINGS"
24
25while ! grep -E -wf "$STRINGS" "$FILE"; do
26 sleep 2
27done
28
29if grep -E -wf "$ERRORS" "$FILE"; then
30 exit 1
31fi
Note: See TracBrowser for help on using the repository browser.

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette