Commit 0ecfb357 authored by Ivan Zakharyaschev's avatar Ivan Zakharyaschev Committed by Michael Shigorin

profile.mk: safer find/grep

Don't go crazy if Dir::Etc::sourceparts/d gives something strange (e.g., /).
parent 26cf3225
......@@ -53,8 +53,8 @@ profile/init: distclean
eval `apt-config shell $${APTCONF:+-c=$$APTCONF} \
SOURCELIST Dir::Etc::sourcelist/f \
SOURCEPARTS Dir::Etc::sourceparts/d`; \
find "$$SOURCEPARTS" -name '*.list' \
| xargs egrep -Rhv '^#|^[[:blank:]]*$$' "$$SOURCELIST" \
find -mindepth 1 -maxdepth 1 "$$SOURCEPARTS" -name '*.list' \
| xargs egrep -hv -e '^#|^[[:blank:]]*$$' -- "$$SOURCELIST" \
| tee $(BUILDDIR)/sources.list; \
echo; \
} $(LOG); \
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment