# bt1 accepts only a directory while bt2 accepts either the metadata
# file directly or a directory with an immediate metadata file.
# Settle for the common denominator.
- metadata_path=$(find "${expected_path}/${session_name}"* | grep metadata)
+ metadata_path=$(find "${expected_path}/${session_name}"* -name "metadata")
metadata_path=$(dirname "$metadata_path")
$BABELTRACE_BIN --output-format=ctf-metadata "${metadata_path}" > "$metadata"
# bt1 accepts only a directory while bt2 accepts either the metadata
# file directly or a directory with an immediate metadata file.
# Settle for the common denominator.
- metadata_path=$(find "${expected_path}/${session_name}"* | grep metadata)
+ metadata_path=$(find "${expected_path}/${session_name}"* -name "metadata")
metadata_path=$(dirname "$metadata_path")
$BABELTRACE_BIN --output-format=ctf-metadata "${metadata_path}" > "$metadata"
# bt1 accepts only a directory while bt2 accepts either the metadata
# file directly or a directory with an immediate metadata file.
# Settle for the common denominator.
- metadata_path=$(find "${expected_path}/${session_name}"* | grep metadata)
+ metadata_path=$(find "${expected_path}/${session_name}"* -name "metadata")
metadata_path=$(dirname "$metadata_path")
$BABELTRACE_BIN --output-format=ctf-metadata "${metadata_path}" 1> "$metadata"
validate_trace $EVENT_NAME $TRACE_PATH/$HOSTNAME/$SESSION_NAME*
# Find the metadata file
- metadata_path=$(find "$TRACE_PATH/$HOSTNAME/$SESSION_NAME"* | grep metadata)
+ metadata_path=$(find "$TRACE_PATH/$HOSTNAME/$SESSION_NAME"* -name "metadata")
# Empty the metadata file
echo -n > "$metadata_path"
validate_trace $EVENT_NAME "$TRACE_PATH"
# Find the metadata file
- metadata_path=$(find "$TRACE_PATH"* | grep metadata)
+ metadata_path=$(find "$TRACE_PATH"* -name "metadata")
# Empty the metadata file
echo -n > "$metadata_path"
validate_trace $EVENT_NAME "$TRACE_PATH/$HOSTNAME/$SESSION_NAME"*
# Find the metadata file
- metadata_path=$(find "$TRACE_PATH/$HOSTNAME/$SESSION_NAME"* | grep metadata)
+ metadata_path=$(find "$TRACE_PATH/$HOSTNAME/$SESSION_NAME"* -name "metadata")
# Empty the metadata file
echo -n > "$metadata_path"
validate_trace $EVENT_NAME "$TRACE_PATH"
# Find the metadata file
- metadata_path=$(find "$TRACE_PATH"* | grep metadata)
+ metadata_path=$(find "$TRACE_PATH"* -name "metadata")
# Empty the metadata file
echo -n > "$metadata_path"
local nr_event_id=$2
local trace_path=$3
- local metadata_file=$(find $trace_path | grep metadata)
+ local metadata_file=$(find $trace_path -name "metadata")
local metadata_path=$(dirname $metadata_file)
which $BABELTRACE_BIN >/dev/null