From 4fe2cd2581553250be14ca3da80ddf046feb78a9 Mon Sep 17 00:00:00 2001 From: Adam Mitz Date: Fri, 11 Jul 2008 15:19:35 +0000 Subject: ChangeLogTag: Fri Jul 11 15:18:27 UTC 2008 Adam Mitz --- vs_postclean.pl | 30 ++++++++++++++++++++++++++++-- 1 file changed, 28 insertions(+), 2 deletions(-) (limited to 'vs_postclean.pl') diff --git a/vs_postclean.pl b/vs_postclean.pl index c8923938..01d7a111 100755 --- a/vs_postclean.pl +++ b/vs_postclean.pl @@ -17,6 +17,7 @@ eval '(exit $?0)' && eval 'exec perl -w -S $0 ${1+"$@"}' use strict; use FileHandle; use File::Basename; +use Cwd; # ****************************************************************** # Data Section @@ -60,6 +61,11 @@ sub read_proj { close($fh); } + $cmd =~ s/&/&/g; + $cmd =~ s/"/\'/g; + $cmd =~ s/>/>/g; + $cmd =~ s/</) { + if (/^Project\([^)]+\) = "[^\"]+", "([^\"]+)"/) { + clean_proj($cfg, $1); + } + } + close($fh); + } +} + # ****************************************************************** # Main Section # ****************************************************************** if ($#ARGV == -1) { print "PostClean v$version\n", - "Usage: ", basename($0), " [CFG=] \n"; + "Usage: ", basename($0), " [CFG=] \n"; exit(0); } @@ -98,5 +120,9 @@ if ($ARGV[0] =~ /^CFG=(.+)/) { } foreach my $file (@ARGV) { - clean_proj($cfg, $file); + if (substr($file, -4, 4) eq '.sln') { + clean_sln($cfg, $file); + } else { + clean_proj($cfg, $file); + } } -- cgit v1.2.1