fix again!

This commit is contained in:
emmett1
2019-06-15 00:26:06 +08:00
parent c9e26fb4c4
commit 45d4cdaa40
3 changed files with 3 additions and 3 deletions

2
pkgadd
View File

@@ -284,7 +284,7 @@ if [ "$UPGRADE_PKG" ] || [ "$REINSTALL_PKG" ]; then
rm "$ROOT_DIR/$line" &>/dev/null
done
grep '/$' $TMP_PKGADD_RMLIST | tac | while read -r line; do
if ! grep -Rx "$line" "$INDEX_DIR"/*/.files | grep -v "$INDEX_DIR"/$name/.files; then
if ! grep -Rqx "$line" "$INDEX_DIR"/*/.files | grep -v "$INDEX_DIR"/$name/.files; then
[ "$VERBOSE_INSTALL" = yes ] && echo "- $line"
rmdir "$ROOT_DIR/$line" &>/dev/null
fi

2
pkgdel
View File

@@ -175,7 +175,7 @@ while read -r line; do
done < <(tac $INDEX_DIR/$name/.files | grep -v '/$')
while read -r line; do
if grep -Rx "$line" "$INDEX_DIR"/*/.files | grep -v "$INDEX_DIR"/$name/.files; then
if grep -Rqx "$line" "$INDEX_DIR"/*/.files | grep -v "$INDEX_DIR"/$name/.files; then
if [ -d "$ROOT_DIR/$line" ]; then
[ "$VERBOSE_REMOVE" = yes ] && echo "- $line"
rmdir "$ROOT_DIR/$line"

View File

@@ -489,7 +489,7 @@ scratch_info() {
scratch_trigger() {
needroot "Run trigger"
if [ -z "$@" ]; then
if [[ -z "$@" ]]; then
for i in trig_{1..12}; do
eval $i=1
done