From 869a38ba87e998889b27248f1595746c0e714170 Mon Sep 17 00:00:00 2001 From: Guilhem Moulin Date: Tue, 10 Jan 2012 20:51:24 +0100 Subject: support for multi-directors --- videomv.pl | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/videomv.pl b/videomv.pl index a21bc33..9ba34c5 100755 --- a/videomv.pl +++ b/videomv.pl @@ -419,6 +419,13 @@ if (&is_symlink($real_new_path)) { $new_director =~ tr@/@_@; $new_director =~ s/[[:cntrl:]]//; + my @new_directors = split / *, */, $new_director; + die "Can't find a suitable director.\n" unless @new_directors; + my $lastdir = pop @new_directors; + $new_director = join ", ", @new_directors; + $new_director .= " & " if @new_directors; + $new_director .= $lastdir; + # Create directory if it doesn't exist my $new_dirname = catfile ($directors, $new_director); unless (-d $new_dirname) { -- cgit v1.2.3