Add log
This commit is contained in:
parent
49e5dcddf4
commit
26f58dcaa6
7 changed files with 40 additions and 13 deletions
|
@ -2,9 +2,9 @@
|
|||
|
||||
# Install missing packages
|
||||
DEB_PACKAGES_LIST="screen libnet-ldap-perl libxml-libxml-perl libgearman-client-perl libmailtools-perl libdatetime-format-iso8601-perl libnet-ip-perl libsys-gamin-perl libdigest-sha-perl libemail-mime-perl libemail-sender-perl"
|
||||
ARCH_PACKAGES_LIST="screen perl-io-socket-ssl perl-email-simple perl-email-mime perl-term-readkey perl-ldap perl-lwp-protocol-https perl-datetime-format-iso8601 perl-net-ip" # aur/perl-sys-gamin
|
||||
GENTOO_PACKAGES_LIST="app-misc/screen dev-perl/IO-Socket-SSL dev-perl/Email-Simple dev-perl/Email-MIME dev-perl/TermReadKey dev-perl/perl-ldap dev-perl/LWP-Protocol-https dev-perl/DateTime-Format-ISO8601 dev-perl/Net-IP"
|
||||
FBSD_PACKAGES_LIST="screen p5-IO-Socket-SSL p5-Email-Simple p5-Email-MIME p5-Term-ANSIColor p5-Term-ReadKey p5-LWP-Protocol-https p5-DateTime-Format-ISO8601 p5-Net-IP p5-Sys-Gamin"
|
||||
ARCH_PACKAGES_LIST="screen perl-io-socket-ssl perl-email-mime perl-term-readkey perl-ldap perl-lwp-protocol-https perl-datetime-format-iso8601 perl-net-ip" # aur/perl-sys-gamin
|
||||
GENTOO_PACKAGES_LIST="app-misc/screen dev-perl/IO-Socket-SSL dev-perl/Email-MIME dev-perl/TermReadKey dev-perl/perl-ldap dev-perl/LWP-Protocol-https dev-perl/DateTime-Format-ISO8601 dev-perl/Net-IP dev-perl/Email-Sender"
|
||||
FBSD_PACKAGES_LIST="screen p5-IO-Socket-SSL p5-Email-MIME p5-Term-ANSIColor p5-Term-ReadKey p5-LWP-Protocol-https p5-DateTime-Format-ISO8601 p5-Net-IP p5-Sys-Gamin"
|
||||
|
||||
KERNEL=`uname -s`
|
||||
|
||||
|
|
|
@ -14,10 +14,10 @@ fi
|
|||
|
||||
if [ "x${1:0:2}" = "x20" ]
|
||||
then
|
||||
YEAR=" <param name=\"year\">$1</param>"
|
||||
YEAR="$1"
|
||||
shift
|
||||
else
|
||||
YEAR=
|
||||
YEAR=`ldapsearch -x -b "cn=year,dc=acu,dc=epita,dc=fr" | grep "^year" | cut -d " " -f 2`
|
||||
fi
|
||||
PROJECT_ID=$1
|
||||
RENDU=$2
|
||||
|
@ -36,7 +36,7 @@ cat <<EOF | gearman -h gearmand -p 4730 -f moulette_get
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<process>
|
||||
<param name="type">moulette</param>
|
||||
$YEAR
|
||||
<param name="year">$YEAR</param>
|
||||
<param name="id">$PROJECT_ID</param>
|
||||
<param name="rendu">$RENDU</param>
|
||||
$LOGINS</process>
|
||||
|
|
|
@ -1,8 +1,13 @@
|
|||
#!/bin/sh
|
||||
|
||||
if [ -z "$2" ]
|
||||
usage()
|
||||
{
|
||||
echo "Usage: $0 [-d] [year] <project> <submission> <login> [login ...]"
|
||||
}
|
||||
|
||||
if [ -z "$3" ]
|
||||
then
|
||||
echo "Usage: $0 [year] <project> <submission> [login ...]"
|
||||
usage
|
||||
exit 1
|
||||
fi
|
||||
|
||||
|
@ -12,6 +17,14 @@ then
|
|||
exit 1
|
||||
fi
|
||||
|
||||
if [ "x$1" = "x-d" ]
|
||||
then
|
||||
BACKGROUD=
|
||||
shift
|
||||
else
|
||||
BACKGROUD="-b"
|
||||
fi
|
||||
|
||||
if [ "x${1:0:2}" = "x20" ]
|
||||
then
|
||||
YEAR=" <param name=\"year\">$1</param>"
|
||||
|
@ -24,10 +37,16 @@ RENDU=$2
|
|||
|
||||
shift 2
|
||||
|
||||
if [ $# -le 0 ]
|
||||
then
|
||||
usage
|
||||
exit 1
|
||||
fi
|
||||
|
||||
while [ $# -gt 0 ]
|
||||
do
|
||||
LOGIN=$1
|
||||
cat <<EOF | gearman -h gearmand -p 4730 -f send_git -b
|
||||
cat <<EOF | gearman -h gearmand -p 4730 -f send_git $BACKGROUD
|
||||
<?xml version="1.0"?>
|
||||
<process>
|
||||
$YEAR
|
||||
|
|
|
@ -31,5 +31,5 @@ map {
|
|||
for my $member (@{ $_->{stds} }) {
|
||||
print ' '.$member->{login};
|
||||
}
|
||||
say "\n R = \@chefs \@resp-$year-$projid";
|
||||
say "\n R = \@chefs \@resp-$year-$projid \@soutenance-$year-$projid";
|
||||
} @{ $res->{groups} };
|
||||
|
|
Reference in a new issue