Gentoo Archives: gentoo-commits

From: "Chris Gianelloni (wolf31o2)" <wolf31o2@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo commit in users/wolf31o2: keyword
Date: Fri, 14 Sep 2007 22:16:27
Message-Id: E1IWJLT-0005rw-N6@stork.gentoo.org
1 wolf31o2 07/09/14 22:09:03
2
3 Modified: keyword
4 Log:
5 Updating to the latest version of my script.
6
7 Revision Changes Path
8 1.7 users/wolf31o2/keyword
9
10 file : http://sources.gentoo.org/viewcvs.py/gentoo/users/wolf31o2/keyword?rev=1.7&view=markup
11 plain: http://sources.gentoo.org/viewcvs.py/gentoo/users/wolf31o2/keyword?rev=1.7&content-type=text/plain
12 diff : http://sources.gentoo.org/viewcvs.py/gentoo/users/wolf31o2/keyword?r1=1.6&r2=1.7
13
14 Index: keyword
15 ===================================================================
16 RCS file: /var/cvsroot/gentoo/users/wolf31o2/keyword,v
17 retrieving revision 1.6
18 retrieving revision 1.7
19 diff -u -r1.6 -r1.7
20 --- keyword 12 Dec 2006 16:43:36 -0000 1.6
21 +++ keyword 14 Sep 2007 22:09:03 -0000 1.7
22 @@ -3,6 +3,7 @@
23 EMAIL="wolf31o2@g.o"
24 CVSROOT="/var/cvsroot/gentoo-x86"
25 COMMIT="yes"
26 +SENDMAIL="/usr/sbin/sendmail"
27
28 usage() {
29 echo "$(basename ${0}): <keyword> <input file> [bug #]"
30 @@ -21,7 +22,8 @@
31 check_failed() {
32 if [ "${ret}" -ne 0 ]
33 then
34 - failed_packages="${failed_packages} ${package}"
35 + failed_packages="${failed_packages}
36 + ${package}"
37 fi
38 }
39
40 @@ -40,11 +42,12 @@
41 do
42 ebuild="$(echo ${package} | cut -d"/" -f2)-${version}"
43 cd ${CVSROOT}/${package}
44 + echo "DEBUG: ${package}"
45 cvs up
46 if [ $(echo ${1} | grep '^~') ]
47 then
48 ekeyword ${1} ${ebuild}.ebuild
49 - elif [ -n "$(grep "~${1}" ${ebuild}.ebuild | grep -v ~x86-fbsd)" ]
50 + elif [ -n "$(grep "~${1}" ${ebuild}.ebuild)" ] # | grep -v ~x86-fbsd)" ]
51 then
52 ekeyword ${1} ${ebuild}.ebuild
53 fi
54 @@ -55,9 +58,9 @@
55 # we remove the file, then start over on just this one package.
56 for package in ${packages}
57 do
58 + ebuild="$(echo ${package} | cut -d"/" -f2)-${version}"
59 for version in $(grep "${package} " /tmp/cpv.txt | cut -d" " -f2)
60 do
61 - ebuild="$(echo ${package} | cut -d"/" -f2)-${version}"
62 cd ${CVSROOT}/${package}
63 if [ "$(cvs up | grep ^C | grep ${ebuild}.ebuild | cut -d" " -f1)" == "C" ]
64 then
65 @@ -71,6 +74,7 @@
66 rm -f .#*
67 if [ "$(cvs up | grep ^M | cut -d" " -f1)" == "M" ]
68 then
69 + ebuild ${ebuild} digest
70 repoman scan
71 ret=$?
72 check_failed
73 @@ -99,5 +103,5 @@
74
75 if [ -n "${failed_packages}" ]
76 then
77 - echo -e "From: ${EMAIL}\r\nTo: ${EMAIL}\r\nSubject: Failed commits\r\n\r\nThis email is to let you know that the following packages failed.\r\nYou will need to fix these packages manually.\r\n${failed_packages}\r\n" | sendmail -f ${EMAIL} ${EMAIL}
78 + echo -e "From: ${EMAIL}\r\nTo: ${EMAIL}\r\nSubject: Failed commits\r\n\r\nThis email is to let you know that the following packages failed keywording for ${1}.\r\nYou will need to fix these packages manually.\r\n${failed_packages}\r\n" | ${SENDMAIL} -f ${EMAIL} ${EMAIL}
79 fi
80
81
82
83 --
84 gentoo-commits@g.o mailing list