🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: es.comp.os.linux.programacion
Article #1382

Re: borrar recursivamente utilizando una mascara

#1382
From: iarenaza
Date: Tue, 24 Jan 2006 20:55
29 lines
2165 bytes
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

>>>>> "Ricardo" == Ricardo Palomares Martinez <rpm.PUBLI@iespana.es> writes:

    Ricardo> $ find . -name *.bak -exec rm -f {} \;

Que s�lo funcionara si lo que se quiere borrar es un fichero, pero no
si es un directorio :-) Ademas de tener que 'quotear' el caracter '*',
ya que es un caracter especial para el shell.

En ese caso, o bien se usa 'rm -rf', o bien se indica explicitamente
que s�lo se desea borrar ficheros con:

    find . -type f -name "*".bak -exec rm -f {} \;

Saludos. I�aki.

- -- 
  Get PGP/GPG Keys at  http://www.escomposlinux.org/iarenaza/pgpkey.php
  I use free software / Yo uso software libre
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.1 (GNU/Linux)
Comment: Processed by Mailcrypt 3.5.8 <http://mailcrypt.sourceforge.net/>

iD8DBQFD1pRBZXLnGT1HLgcRAgtgAJ9hYMXMBlDJz0Vrvvpe4NWnzTW9agCfc/SA
0wuFIUiS6xsakeKbGfZR3J4=
=bSTF
-----END PGP SIGNATURE-----
Technical Details
Message-ID: <87zmll1h31.fsf@barad-dur.escomposlinux.org>
Path: arc1-ca.pugleaf.net!g2news1.google.com!news2.google.com!news4.google.com!news.glorb.com!newspeer1.se.telia.net!newspeer4.se.telia.net!se.telia.net!fu-berlin.de!news.eteo.mondragon.edu!eteo.mondragon.edu!not-for-mail
References: <dr3gec$hjh$1@negre.bartolo> <sh1ga3-mqt.ln1@Father.family>

Show Full Headers
Complete Article Headers
X-Google-Thread: f86c8,4759451d56775892
X-Google-Attributes: gidf86c8,public
X-Google-Language: ENGLISH,ASCII
Path: arc1-ca.pugleaf.net!g2news1.google.com!news2.google.com!news4.google.com!news.glorb.com!newspeer1.se.telia.net!newspeer4.se.telia.net!se.telia.net!fu-berlin.de!news.eteo.mondragon.edu!eteo.mondragon.edu!not-for-mail
From: <iarenaza@eb2ebu.ampr.org> (Iñaki Arenaza)
Newsgroups: es.comp.os.linux.programacion
Subject: Re: borrar recursivamente utilizando una mascara
Date: Tue, 24 Jan 2006 21:55:30 +0100
Organization: Mondragon Unibertsitatea - ETEO
Lines: 29
Distribution: es
Message-ID: <87zmll1h31.fsf@barad-dur.escomposlinux.org>
References: <dr3gec$hjh$1@negre.bartolo> <sh1ga3-mqt.ln1@Father.family>
NNTP-Posting-Host: 22.red-80-38-245.staticip.rima-tde.net
Mime-Version: 1.0
Content-Type: text/plain; charset=iso-8859-1
Content-Transfer-Encoding: 8bit
X-Trace: sid.eteo.mondragon.edu 1138136129 20107 80.38.245.22 (24 Jan 2006 20:55:29 GMT)
X-Complaints-To: newsmaster@eteo.mondragon.edu
NNTP-Posting-Date: Tue, 24 Jan 2006 20:55:29 +0000 (UTC)
User-Agent: Gnus/5.1006 (Gnus v5.10.6) Emacs/21.4 (gnu/linux)
Cancel-Lock: sha1:zS2EiajQyPcv9PNjZcQCejYV+cw=