Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 20 Apr 2003 22:10:06 -0000
From:      Kirill Ponomarew <ponomarew@oberon.net>
To:        FreeBSD-gnats-submit@FreeBSD.org
Subject:   ports/51198: New port: sysutils/chgrep 
Message-ID:  <E197MyA-000H3a-00@voodoo.oberon.net>
Resent-Message-ID: <200304202210.h3KMA3AT046501@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         51198
>Category:       ports
>Synopsis:       New port: sysutils/chgrep
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Sun Apr 20 15:10:03 PDT 2003
>Closed-Date:
>Last-Modified:
>Originator:     Kirill Ponomarew
>Release:        FreeBSD 4.8-RELEASE i386
>Organization:
Oberon.net 
>Environment:
FreeBSD voodoo.oberon.net 4.8-RELEASE FreeBSD 4.8-RELEASE #1: Wed Apr  2 12:24:32 CEST 2003     root@voodoo.oberon.net:/usr/obj/usr/src/sys/FREAK  i386
 
        
>Description:
New port: sysutils/chgrep 

Chgrep searches the input files (or standard input if no files are named)
for oldstring and changes them to new string. If some file and file.lock
exist then chgrep leaves both files unchanged. This program can be very use-
full for mail servers. Chgrep is fast, much faster than grep or sed.

>How-To-Repeat:

>Fix:

# This is a shell archive.  Save it in a file, remove anything before
# this line, and then unpack it by entering "sh file".  Note, it may
# create directories; files and directories will be owned by you and
# have default permissions.
#
# This archive contains:
#
#	sysutils/chgrep/files/patch-src::chgrep.c
#	sysutils/chgrep/Makefile
#	sysutils/chgrep/distinfo
#	sysutils/chgrep/files
#	sysutils/chgrep/pkg-descr
#	sysutils/chgrep/pkg-plist
#
echo x - sysutils/chgrep/files/patch-src::chgrep.c
sed 's/^X//' >sysutils/chgrep/files/patch-src::chgrep.c << 'END-of-sysutils/chgrep/files/patch-src::chgrep.c'
X--- src/chgrep.c.orig	Sun Apr 20 22:58:09 2003
X+++ src/chgrep.c	Sun Apr 20 22:58:18 2003
X@@ -132,11 +132,6 @@
X 		file_quit = NULL;
X 		tmpfile_quit = NULL;
X 
X-		if (recursive) {
X-			ftw(argv[opttmp], list, sysconf(_SC_OPEN_MAX));
X-			return 0;
X-		}
X-
X 		if ( ! istmpfilename) {	/* if we don't use -t filename.tmp */
X 			strcat(strcpy(tmpfile, argv[opttmp]), ".lock");
X 			if ( (fdout = open(tmpfile, O_RDONLY, PERM)) != -1) {
END-of-sysutils/chgrep/files/patch-src::chgrep.c
echo x - sysutils/chgrep/Makefile
sed 's/^X//' >sysutils/chgrep/Makefile << 'END-of-sysutils/chgrep/Makefile'
X# Ports collection makefile for:       	chgrep
X# Date created:                 April 20, 2003
X# Whom:                        	Kirill Ponomarew <ponomarew@oberon.net>
X#
X# $FreeBSD$
X#
X
XPORTNAME=       chgrep
XPORTVERSION=   	1.1.0
XCATEGORIES=    	sysutils
XMASTER_SITES=  	http://www.bmk.bicom.pl/chgrep/
XDISTNAME=	${PORTNAME}-${PORTVERSION}
XEXTRACT_SUFX=	.tgz
X
XMAINTAINER=    	ponomarew@oberon.net
XCOMMENT=      	Change oldpatter to newpattern in lines
X
XGNU_CONFIGURE=	yes
XUSE_GMAKE=	yes
X
XMAN1=		chgrep.1
X
Xdo-install:
X	@${INSTALL_PROGRAM} ${WRKSRC}/src/chgrep ${PREFIX}/bin
X	${INSTALL_MAN} ${WRKSRC}/man/chgrep.1 ${MANPREFIX}/man/man1
X
X.include <bsd.port.mk>
END-of-sysutils/chgrep/Makefile
echo x - sysutils/chgrep/distinfo
sed 's/^X//' >sysutils/chgrep/distinfo << 'END-of-sysutils/chgrep/distinfo'
XMD5 (chgrep-1.1.0.tgz) = 4822ae4efc6590ed9fb231cea4f14f16
END-of-sysutils/chgrep/distinfo
echo c - sysutils/chgrep/files
mkdir -p sysutils/chgrep/files > /dev/null 2>&1
echo x - sysutils/chgrep/pkg-descr
sed 's/^X//' >sysutils/chgrep/pkg-descr << 'END-of-sysutils/chgrep/pkg-descr'
XChgrep searches the input files (or standard input if no files are named)
Xfor oldstring and changes them to new string. If some file and file.lock
Xexist then chgrep leaves both files unchanged. This program can be very use-
Xfull for mail servers. Chgrep is fast, much faster than grep or sed.
X
XWWW: http://www.bmk.bicom.pl/chgrep
END-of-sysutils/chgrep/pkg-descr
echo x - sysutils/chgrep/pkg-plist
sed 's/^X//' >sysutils/chgrep/pkg-plist << 'END-of-sysutils/chgrep/pkg-plist'
Xbin/chgrep
END-of-sysutils/chgrep/pkg-plist
exit

>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?E197MyA-000H3a-00>