All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH OSSTEST v8 1/2] cr-publish-flight-logs: allow publishing only the Results
@ 2015-07-09 14:30 Ian Campbell
  2015-07-09 14:30 ` [PATCH OSSTEST v8 2/2] mg-all-branch-statuses: Show how up to date each branch is Ian Campbell
  2015-07-09 15:34 ` [PATCH OSSTEST v8 1/2] cr-publish-flight-logs: allow publishing only the Results Ian Jackson
  0 siblings, 2 replies; 5+ messages in thread
From: Ian Campbell @ 2015-07-09 14:30 UTC (permalink / raw)
  To: ian.jackson; +Cc: Ian Campbell, xen-devel

Removing the requirement that a flight be provided allows this to be
used to publish the results directory even in contexts which have no
flight.

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
---
v7: New patch

v8: No need for a list of files, just allow to omit publishing flight.
    Therefore flight becomes optional.

    Renamed from : cr-publish-flight-logs: support publishing files from $HOME/public_html
---
 cr-publish-flight-logs | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

diff --git a/cr-publish-flight-logs b/cr-publish-flight-logs
index 94c74c8..8a19d88 100755
--- a/cr-publish-flight-logs
+++ b/cr-publish-flight-logs
@@ -31,10 +31,10 @@ if (@ARGV && $ARGV[0] eq '--push-harness') {
     $push_harness = 1;
 }
 
-die "usage: ./cr-publish-flight-logs <flight>" unless @ARGV==1;
+my $flight= shift @ARGV // '';
+die unless $flight =~ m/^\d*$/;
 
-my $flight= shift @ARGV;
-die unless $flight =~ m/^\d+$/;
+die "usage: ./cr-publish-flight-logs [flight]" unless @ARGV==0;
 
 open LOCK, "> $c{GlobalLockDir}/publish-lock" or die $!;
 flock LOCK, LOCK_EX or die $!;
@@ -59,5 +59,6 @@ sub copydir ($$) {
     $!=0; $?=0; system @cmd; die "rsync $? $!" if $? or $!;
 }
 
-copydir("$c{Logs}/$flight/", "$c{LogsPublish}/$flight") if $c{LogsPublish};
+copydir("$c{Logs}/$flight/", "$c{LogsPublish}/$flight")
+    if $flight && $c{LogsPublish};
 copydir("$c{Results}/", "$c{ResultsPublish}") if $c{ResultsPublish};
-- 
2.1.4

^ permalink raw reply related	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2015-07-13 11:41 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-07-09 14:30 [PATCH OSSTEST v8 1/2] cr-publish-flight-logs: allow publishing only the Results Ian Campbell
2015-07-09 14:30 ` [PATCH OSSTEST v8 2/2] mg-all-branch-statuses: Show how up to date each branch is Ian Campbell
2015-07-09 15:35   ` Ian Jackson
2015-07-13 11:41   ` Ian Campbell
2015-07-09 15:34 ` [PATCH OSSTEST v8 1/2] cr-publish-flight-logs: allow publishing only the Results Ian Jackson

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.