pld-ftp-admin: shell/bashrc - touchpkg() to touch every file from ...

glen glen at pld-linux.org
Mon Jan 21 16:08:21 CET 2008


Author: glen                         Date: Mon Jan 21 15:08:21 2008 GMT
Module: pld-ftp-admin                 Tag: HEAD
---- Log message:
- touchpkg() to touch every file from info file, needed for broken ftp admin scripts, sometimes

---- Files affected:
pld-ftp-admin/shell:
   bashrc (1.5 -> 1.6) 

---- Diffs:

================================================================
Index: pld-ftp-admin/shell/bashrc
diff -u pld-ftp-admin/shell/bashrc:1.5 pld-ftp-admin/shell/bashrc:1.6
--- pld-ftp-admin/shell/bashrc:1.5	Sun Jan  6 02:54:21 2008
+++ pld-ftp-admin/shell/bashrc	Mon Jan 21 16:08:16 2008
@@ -49,6 +49,16 @@
 	done
 }
 
+touchpkg() {
+	local pkg=$1
+	if [ ! -f $pkg ]; then
+		echo >&2 "touchpkg: Specify existing info file"
+		return
+	fi
+	awk -F: '/^file:/{arch=$2; file=$3; printf("../../%s/RPMS/%s\n", arch, file)}' "$@" | \
+	xargs -l512 -r touch
+}
+
 signpkg() {
 	local pkg=$1
 	if [ ! -f $pkg ]; then
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/pld-ftp-admin/shell/bashrc?r1=1.5&r2=1.6&f=u



More information about the pld-cvs-commit mailing list