Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F168460906
D6396.id16396.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
2 KB
Referenced Files
None
Subscribers
None
D6396.id16396.diff
View Options
Index: Tools/scripts/rmport
===================================================================
--- Tools/scripts/rmport
+++ Tools/scripts/rmport
@@ -31,6 +31,7 @@
# Originally written by Vasil Dimov <vd@FreeBSD.org>
# Others:
# Chris Rees <crees@FreeBSD.org>
+# Rene Ladan <rene@FreeBSD.org>
#
# $FreeBSD$
#
@@ -107,7 +108,7 @@
{
EXPVAR=EXPIRATION_DATE
- find ${PORTSDIR} -mindepth 3 -maxdepth 3 -name "Makefile*" \
+ find -H ${PORTSDIR} -mindepth 3 -maxdepth 3 -name "Makefile*" \
|xargs grep -H ${EXPVAR} \
|sed -E "s|${PORTSDIR}/?([^/]+/[^/]+)/Makefile:${EXPVAR}=[[:space:]]*([0-9-]{10})$|\2 \1|g" \
|perl -ne "if ((substr(\$_, 0, 10) cmp '${TODAY}') <= 0) { print(\$_); }" \
@@ -162,7 +163,7 @@
# check if some Makefiles mention the port to be deleted
portdir_grep="^[^#].*/`basename ${catport}`([[:space:]]|/|$)"
- r="`find ${PORTSDIR} -mindepth 2 -maxdepth 3 \
+ r="`find -H ${PORTSDIR} -mindepth 2 -maxdepth 3 \
\( -name "Makefile*" -or -path "*Mk/*.mk" \) \
|xargs grep -EH "${portdir_grep}" \
|grep -vE "^(${rmcatports})" || :`"
@@ -210,18 +211,16 @@
fi
}
-# query GNATS via query-pr-summary.cgi, format and return the result
+# query GNATS via Bugzilla, format and return the result
+# XXX rene: PRs are listed twice for now due to the HTML code of Bugzilla
get_PRs_www()
{
catport=${1}
synopsis=${2}
- date_re='[0-9]{4}/[0-9]{2}/[0-9]{2}'
- prnum_re='.+/[0-9]{5,6}'
- synopsis_re='.{10,}'
log "${catport}: getting PRs having ${synopsis} in the synopsis"
- url="http://www.freebsd.org/cgi/query-pr-summary.cgi?text=${synopsis}"
+ url="https://bugs.freebsd.org/bugzilla/buglist.cgi?quicksearch=${synopsis}"
raw="`fetch -q -T 20 -o - "${url}"`"
@@ -231,28 +230,17 @@
fi
printf "%s" "${raw}" \
- |sed -nE "s|.*>(${date_re})<.*>(${prnum_re})<.*>(${synopsis_re})</td.*|\1 \2 \3|p" \
+ |grep "show_bug.cgi?id=" \
|sort
}
-# query GNATS via query-pr on freefall and return the result
-get_PRs_freefall()
-{
- catport=${1}
- synopsis=${2}
-
- log "${catport}: getting PRs having ${synopsis} in the synopsis"
-
- ssh freefall.freebsd.org "query-pr -qx -y '${synopsis}' || :"
-}
-
# query GNATS and return the result
get_PRs()
{
catport=${1}
synopsis=${2}
- get_PRs_freefall ${catport} ${synopsis}
+ get_PRs_www ${catport} ${synopsis}
}
# check if any PRs exist that are related to the port
@@ -419,7 +407,7 @@
rm svnlog
# release ports directories
- rm -r ports
+ rm -rf ports
cd /
rmdir ${codir}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sat, Aug 29, 12:37 PM (12 h, 30 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
37511337
Default Alt Text
D6396.id16396.diff (2 KB)
Attached To
Mode
D6396: Tools/scripts/rmport: update for Bugzilla and usability improvements
Attached
Detach File
Event Timeline
Log In to Comment