From owner-freebsd-questions@FreeBSD.ORG Wed Dec 31 12:03:16 2003 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A90E016A4CE for ; Wed, 31 Dec 2003 12:03:16 -0800 (PST) Received: from ns1.tiadon.com (SMTP.tiadon.com [69.27.132.161]) by mx1.FreeBSD.org (Postfix) with ESMTP id 68F5143D31 for ; Wed, 31 Dec 2003 12:03:14 -0800 (PST) (envelope-from kdk@daleco.biz) Received: from daleco.biz ([69.27.131.0]) by ns1.tiadon.com with Microsoft SMTPSVC(6.0.3790.0); Wed, 31 Dec 2003 14:06:27 -0600 Message-ID: <3FF32B39.2070906@daleco.biz> Date: Wed, 31 Dec 2003 14:02:01 -0600 From: "Kevin D. Kinsey, DaleCo, S.P." User-Agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.5) Gecko/20031124 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Chris References: <000f01c3cfd3$5aa7a090$0901a8c0@bloodlust> <200312311329.49998.racerx@makeworld.com> In-Reply-To: <200312311329.49998.racerx@makeworld.com> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-OriginalArrivalTime: 31 Dec 2003 20:06:27.0937 (UTC) FILETIME=[931ADD10:01C3CFD9] cc: Xpression cc: FreeBSD-questions Subject: Re: tar question... X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 31 Dec 2003 20:03:16 -0000 Chris wrote: >On Wednesday 31 December 2003 1:21 pm, Xpression wrote: > > >>Hi list, I've googled to search an aswer but no one match >>mine. I want to tar all files on a directory without include >>any other directory, I've tried with --exclude but no hope, >>any suggestion ??? Thanks... >> >> >> > >I dom something similar to what you ask. What I do is tar a directory and all >it's contense EXCEPT one diectory. It goes something like this: > >tar -zcf name.tgz --exclude MP3 dirname/ > >Explanation: > >I'm tarring a dir. and excluding the dir MP3 and it's files. >I'm sure you will be able to expand on this. > >Use man tar to see all the switches. > > Sounds find, but wouldn't $tar /home/foo/* get this job done without including subdirs, since there's no -R involved? I read the OP's question as "I want to tar all the files in a directory without including any other directories..." which would mean "any (sub)directories within the directory would not be placed in the tarball", right? Kevin Kinsey DaleCo, S.P.