From 23fd1cb0846a94ec6b9f653d123ad56e5cdd8efb Mon Sep 17 00:00:00 2001 From: agiersch Date: Tue, 12 Oct 2010 12:46:18 +0000 Subject: [PATCH 1/1] Really do the s/:/_/ in platform upgrading script. git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/simgrid/simgrid/trunk@8403 48e7efb5-ca39-0410-a469-dd3cf9ba447f --- tools/simgrid_update_xml.pl | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/tools/simgrid_update_xml.pl b/tools/simgrid_update_xml.pl index 226d8492cb..2ca57b959b 100755 --- a/tools/simgrid_update_xml.pl +++ b/tools/simgrid_update_xml.pl @@ -1,7 +1,7 @@ #! /usr/bin/perl # This script updates the simgrid XML file passed as argument (modification in place) -# It is built to do the conversion incrementally (even if for now, only 2 versions are defined) +# It is built to do the conversion incrementally. # Copyright (C) 2006-2010. The SimGrid team. All rights reserved. # @@ -72,14 +72,12 @@ while (defined($line = )) { } if ($fromversion < 3) { - if($line =~ /^(.*)<\/platform>(.*)$/) { - $output_string .= " <\/AS>\n<\/platform>"; - } else { - $output_string .= "$line\n"; - } $line =~ s/\blink:ctn\b/link_ctn/g; $line =~ s/\btrace:connect\b/trace_connect/g; + $line =~ s/^(.*)<\/platform>(.*)$/ <\/AS>\n<\/platform>/; } + + $output_string .= "$line\n"; } close INPUT; -- 2.20.1