LT 81: auto-build: Directory in url and output in yaml.

Index: ChangeLog from Nicolas Pouillard <ertai@lrde.epita.fr> * auto-build/auto-build: Make it print its output in yaml. Accept a directory in url. Index: auto-build/auto-build --- auto-build/auto-build (revision 80) +++ auto-build/auto-build (working copy) @@ -103,7 +103,7 @@ &gen_summary; foreach my $pkg (@packages) { - print "$pkg->{'name'}\n"; + print "$pkg->{'name'}:\n"; &ch_dir($build_dir); next if &check_revision($pkg); @@ -387,7 +387,7 @@ $_[0]->{'status'} = $_[1]; system("echo \"$_[1]\" > \"$build_dir/$_[0]->{'name'}/.status\"") and die "$0: unable to create `$build_dir/$_[0]->{'name'}/.status'\n"; - print " $_[1]\n"; + print " - $_[1]\n"; &gen_summary; } @@ -495,7 +495,20 @@ }; } - if (m|^file://(.*)$|) { + if (m|^file://(.*)$| and -d $1 and /^([^\/]*)\/(.*)$/) { + my $dir = $1; + $pkg->{'dir'} = $2; + + push @steps, { + 'name' => 'copy', + 'cmd' => "cp -r \"$dir\" ." + }, { + 'dir' => "echo \"$pkg->{'dir'}\"", + 'name' => 'bootstrap', + 'cmd' => "./bootstrap" + }; + + } elsif (m|^file://(.*)$|) { my $file = $_ = $1; my $c; -- Pouillard Nicolas LRDE CSI 2006 ertai@lrde.epita.fr "Emacs is a nice OS - but it lacks a good text editor. That's why I am using Vim."
participants (1)
-
Ertai