-#!/usr/bin/perl
+#!/usr/bin/env perl
+
+# Copyright (c) 2005-2022. The SimGrid Team.
+# All rights reserved.
+
+# This program is free software; you can redistribute it and/or modify it
+# under the terms of the license (GNU LGPL) which comes with this package.
$col_white = "\033[00m";
$col_black = "\033[30m";
$col_blink = "\033[05m";
# Customize colors here...
-#
$col_default = $col_ltgray;
my (@coltab) = (
$col_green, $col_yellow,
my %pid;
# Get options
-#
while (($_ = $ARGV[0]) =~ /^-/) {
shift;
if (/-location/i) {
my($host,$procname,$pid,$date,$location,$xbt_channel,$message)=@_;
print $col_norm;
- printf "[% 10.3f]",$date;
+ printf "[% 10.6f]",$date;
print pidcolor($pid);
if(defined($location)) {
- printf "[%10s:%-10s %s ]",$host,$procname,$location;
+ printf "[%10s:%-10s] %s ",$host,$procname,$location;
} else {
printf "[%10s:%-10s]",$host,$procname;
}
$orgline = $thisline = $_;
# Typical line [Gatien:slave:(9) 11.243148] msg/gos.c:137: [msg_gos/DEBUG] Action terminated
- if ($thisline =~ /^\[([^:]+):([^:]+):\((\d+)\) ([\d\.]*)\] ([^\[]*) \[([^\[]*)\] (.*)$/) {
+ if ($thisline =~ /^\[(.+):([^:]+):\((\d+)\) ([\d\.]*)\] ([^\[]*) \[([^\[]*)\] (.*)$/) {
$host=$1;
$procname=$2;
$pid=$3;