On 5/9/2019 12:34 AM, David Wright wrote:
On Wed 08 May 2019 at 14:08:03 (+0800), KHMan wrote:
On Tue 07 May 2019 at 10:12:10 (+1000), David wrote:
On Mon, 6 May 2019 at 23:53, Erik Christiansen wrote:
On 06.05.19 09:03, Greg Wooledge wrote:
On Sat, May 04, 2019 at 01:48:01PM +0200, Jonas Sme
On Wed 08 May 2019 at 14:08:03 (+0800), KHMan wrote:
> > On Tue 07 May 2019 at 10:12:10 (+1000), David wrote:
> > > On Mon, 6 May 2019 at 23:53, Erik Christiansen wrote:
> > > > On 06.05.19 09:03, Greg Wooledge wrote:
> > > > > On Sat, May 04, 2019 at 01:48:01PM +0200, Jonas Smedegaard wrote:
> [sn
On Tue 07 May 2019 at 10:12:10 (+1000), David wrote:
On Mon, 6 May 2019 at 23:53, Erik Christiansen wrote:
> On 06.05.19 09:03, Greg Wooledge wrote:
> > On Sat, May 04, 2019 at 01:48:01PM +0200, Jonas Smedegaard wrote:
[snipped all]
Hi Erik
Maybe you would enjoy answering this question then?
h
On Tue 07 May 2019 at 10:12:10 (+1000), David wrote:
> On Mon, 6 May 2019 at 23:53, Erik Christiansen
> wrote:
> > On 06.05.19 09:03, Greg Wooledge wrote:
> > > On Sat, May 04, 2019 at 01:48:01PM +0200, Jonas Smedegaard wrote:
> > > > Quoting Erik Christiansen (2019-05-04 08:43:53)
>
> > > > >
On Sun, Dec 08, 2002 at 12:31:30AM -0600, Michael Heironimus wrote:
> On Sat, Dec 07, 2002 at 08:26:21PM +0100, Frank Gevaerts wrote:
> > > find . -name '*.jpg' -print0 | xargs -r0 mpg123
> >
> > Any special reason not to use -exec (except of course that xargs works
> > with any input, while -ex
On Sat, Dec 07, 2002 at 08:26:21PM +0100, Frank Gevaerts wrote:
> > find . -name '*.jpg' -print0 | xargs -r0 mpg123
>
> Any special reason not to use -exec (except of course that xargs works
> with any input, while -exec only with find (obviously))
I always use xargs instead of find -exec becau
"Bob" == Bob Proulx <[EMAIL PROTECTED]> writes:
Bob> A very slight danger here. If the first filename starts with
Bob> a '-' then test will see this as an option instead of as a
Bob> string and complain. This is why people prefix with a known
Bob> character. Usually using an
Shyamal Prasad <[EMAIL PROTECTED]> [2002-12-07 13:53:57 -0600]:
> if [ "`find . -maxdepth 1 -name '*.jpg' -print`" != "" ]
A very slight danger here. If the first filename starts with a '-'
then test will see this as an option instead of as a string and
complain. This is why people prefix with
Michael Heironimus <[EMAIL PROTECTED]> wrote:
>
> There is a way that looks slightly better, but it's still ugly because
> it relies on bash-specific options. Something like this should do it.
>
> #! /bin/bash
> # Make globs that don't match expand to null string
> shopt -s nullglob
> if [ -n "$(
"Drew" == Drew Cohan <[EMAIL PROTECTED]> writes:
Drew> Hi, Using a bash shell script (/bin/sh), I need to know how
Drew> to check to see if certain files exist in a directory, as
Drew> in, "Are there any jpegs in this directory?". I've tried
Drew> various things (like using -s
On Sat, Dec 07, 2002 at 12:13:11PM -0700, Bob Proulx wrote:
> Frank Gevaerts <[EMAIL PROTECTED]> [2002-12-07 19:58:00 +0100]:
> > On Sat, Dec 07, 2002 at 11:47:54AM -0700, Bob Proulx wrote:
> > > You are trying to find files in a directory. Therefore I recommend
> > > you use the 'find' command.
>
Bob Proulx <[EMAIL PROTECTED]> [2002-12-07 12:13:11 -0700]:
> > find . -name \*.jpg -exec mpg123 {} \;
> I was only proposing the mpg123 as an example. I really don't know
> what the OP wanted to do with it.
You can tell what I was doing in the background while reading and
responding to these mes
Frank Gevaerts <[EMAIL PROTECTED]> [2002-12-07 19:58:00 +0100]:
> On Sat, Dec 07, 2002 at 11:47:54AM -0700, Bob Proulx wrote:
> > You are trying to find files in a directory. Therefore I recommend
> > you use the 'find' command.
> > [..contrived.example...]
> > mp3playlist=$(find . -name '*.jpg'
On Sat, Dec 07, 2002 at 11:47:54AM -0700, Bob Proulx wrote:
> Drew Cohan <[EMAIL PROTECTED]> [2002-12-07 01:00:29 -0500]:
> >
> > Using a bash shell script (/bin/sh), I need to know how to check to see
> > if certain files exist in a directory, as in, "Are there any jpegs in
> > this directory?".
Drew Cohan <[EMAIL PROTECTED]> [2002-12-07 01:00:29 -0500]:
>
> Using a bash shell script (/bin/sh), I need to know how to check to see
> if certain files exist in a directory, as in, "Are there any jpegs in
> this directory?". I've tried various things (like using -s, -f with
> test and a do/for
Gary Turner wrote:
>Drew Cohan wrote:
>>Using a bash shell script (/bin/sh), I need to know how to check to see
>>if certain files exist in a directory, as in, "Are there any jpegs in
>>this directory?".
>
>Try
>
> ls *.jpg > /dev/null 2>&1 # tested command--output is
>
On Sat, Dec 07, 2002 at 01:45:45AM -0500, Travis Crump wrote:
> From the there has got to be a better way department:
>
> ls /opt/images/*.jpg > /dev/null 2>&1 && echo there are jpegs
There is a way that looks slightly better, but it's still ugly because
it relies on bash-specific options. Someth
Drew Cohan wrote:
>Hi,
>
>Using a bash shell script (/bin/sh), I need to know how to check to see
>if certain files exist in a directory, as in, "Are there any jpegs in
>this directory?". I've tried various things (like using -s, -f with
>test and a do/for loop) but nothing seems to work right.
Travis Crump <[EMAIL PROTECTED]> writes:
> Drew Cohan wrote:
>> Hi,
>> Using a bash shell script (/bin/sh), I need to know how to check to see
>> if certain files exist in a directory, as in, "Are there any jpegs in
>> this directory?". I've tried various things (like using -s, -f with
>> test an
Drew Cohan wrote:
Hi,
Using a bash shell script (/bin/sh), I need to know how to check to see
if certain files exist in a directory, as in, "Are there any jpegs in
this directory?". I've tried various things (like using -s, -f with
test and a do/for loop) but nothing seems to work right. The cl
Hi,
Using a bash shell script (/bin/sh), I need to know how to check to see
if certain files exist in a directory, as in, "Are there any jpegs in
this directory?". I've tried various things (like using -s, -f with
test and a do/for loop) but nothing seems to work right. The closest I
can come is
21 matches
Mail list logo