Bug noticed on IRC

Bryan Kadzban bryan at kadzban.is-a-geek.net
Fri Jan 7 10:22:12 PST 2005


On Fri, Jan 07, 2005 at 06:43:00PM +0500, Alexander E. Patrakov wrote:
> [18:36] <patrakov> drop "-k /dev/null"
> [18:36] <patrakov> and then make sure that the /home/lfs directory is empty

I've never used SuSE (any version), but if that is the case, we can drop
-k /dev/null from the command and do this afterward to clean out the
home directory:

rm -r /home/lfs/*
rm -r /home/lfs/.[^.]*
rm -r /home/lfs/..?*

In other words, remove anything that doesn't start with a dot, then
remove anything that does start with a dot but whose second character is
not a dot (so we skip the "." entry), then remove anything that starts
with two dots but has a third character (so we skip the ".." entry).
That explanation would probably be a good way to teach a bit about
globbing also (if we don't assume that our users understand globbing
already).

These globs have been tested with "echo" to ensure that neither . nor ..
are included -- at least, that holds on my version of bash (2.05b on
this box: it's an older LFS install, somewhere before we upgraded to
3.0).  But I don't see any reason it wouldn't hold on any (sane) version
of bash.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <http://lists.linuxfromscratch.org/pipermail/lfs-dev/attachments/20050107/0cf43867/attachment.sig>


More information about the lfs-dev mailing list