mirror of
https://git.FreeBSD.org/src.git
synced 2025-01-20 15:43:16 +00:00
'+' can also appear in a package file name.
Reported by: jhb '^' could also appear in a package file name.
This commit is contained in:
parent
190b2c4f8a
commit
7e92d04c01
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=124088
@ -1,4 +1,5 @@
|
||||
#! /bin/sh
|
||||
# ex:ts=8
|
||||
|
||||
# Copyright (c) 2003 David E. O'Brien
|
||||
# All rights reserved.
|
||||
@ -40,7 +41,11 @@ case $# in
|
||||
esac
|
||||
|
||||
PKG_LIST=$(basename `ls $3/*.${PKG_EXT}` | sed -e "s/\.${PKG_EXT}$//")
|
||||
REGEX=$(echo ${PKG_LIST} | sed -e 's/ /|/g' -e 's/\./\\\./g')
|
||||
REGEX=$(echo ${PKG_LIST} | sed \
|
||||
-e 's/ /|/g' \
|
||||
-e 's/\./\\\./g' \
|
||||
-e 's/\+/\\\+/g' \
|
||||
-e 's/\^/\\\^/g')
|
||||
|
||||
egrep "^(${REGEX})" $1 > $2
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user