From owner-freebsd-questions@FreeBSD.ORG Fri Nov 9 03:17:59 2007 Return-Path: Delivered-To: questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9D6D416A419 for ; Fri, 9 Nov 2007 03:17:59 +0000 (UTC) (envelope-from sdavtaker@gmail.com) Received: from wa-out-1112.google.com (wa-out-1112.google.com [209.85.146.176]) by mx1.freebsd.org (Postfix) with ESMTP id 7469913C491 for ; Fri, 9 Nov 2007 03:17:59 +0000 (UTC) (envelope-from sdavtaker@gmail.com) Received: by wa-out-1112.google.com with SMTP id k17so467504waf for ; Thu, 08 Nov 2007 19:17:52 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:user-agent:mime-version:to:subject:content-type:content-transfer-encoding; bh=V+N/TkKVQfRoH+JxspqEfrN+lr4xTzwz/Ttgu1lSSA8=; b=sCUswjw8tt8sKzCP2Ah2E4f4HsgR8Cvd+c66vFe8OSqf9GBBTqxQXH+R5AR6ZvJyGdEJW2UtDQl9akcYHF4JWp3dRgs4f8cHID3qlEJhyhfV3mIAJWNQFmU+NQivfIlR9p1ZHNideEm5W9CPUyNRJNTSDiYNiOPPf9uzWXM3upk= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:user-agent:mime-version:to:subject:content-type:content-transfer-encoding; b=S4coPdK46aKb41FcBo08Q2WLMI6/T0ZQTnV7gPNHVNi2YUrX+1XcVzRQSOXJUl56x5ASxH2OwosLRMoPO2Z6AX10it3OfKU8KQAyCWv+nBU9cS0UEcxxa86WjxJLHdfRZt04rWyhm/egp3CUftx0//qWCfU0xEIfn1dvfKnDdZU= Received: by 10.114.27.20 with SMTP id a20mr634264waa.1194576560184; Thu, 08 Nov 2007 18:49:20 -0800 (PST) Received: from ?192.168.1.100? ( [190.18.36.119]) by mx.google.com with ESMTPS id 31sm2083683wri.2007.11.08.18.49.17 (version=TLSv1/SSLv3 cipher=RC4-MD5); Thu, 08 Nov 2007 18:49:18 -0800 (PST) Message-ID: <4733CAB4.2080508@gmail.com> Date: Thu, 08 Nov 2007 23:49:24 -0300 From: =?ISO-8859-1?Q?Sd=E4vtaker?= User-Agent: Thunderbird 2.0.0.6 (Windows/20070728) MIME-Version: 1.0 To: questions@freebsd.org Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: quoted-printable Cc: Subject: problems using ls with for_in (SH) X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 09 Nov 2007 03:17:59 -0000 Im trying to get a file with all the md5 hashes of one directory. My initial script was this: #!/bin/sh for file in $(ls) do echo $file md5 $file done The problem is with the file names who contains "whitespaces" becouse=20 the for_in passed each word as one iteration and not the full filename,=20 I'd tried using -B in ls, but doesnt help. Any idea what can i do? Thanks! Sd=E4v