Re: mp3 sorting issues :(

Jeremy Johnstone <[email protected]> Sun, 30 May 2004 02:55:37 -0500
Newsgroups gmane.org.user-groups.aclug.linux-help
Message-ID <[email protected]>
If your still needing help with this, I would be willing to give examples in 
Bash or PHP (CLI). I am not much of a Perl fan so although I could do it in 
Perl, I try to stay away from it.

-Jeremy

On Sunday 18 April 2004 10:25 pm, Carl D Cravens wrote:
> On Sun, 18 Apr 2004 [email protected] wrote:
> > bash .. i kindof hacked together something that is currently working
> > using nested for statements, but it just doesn't feel right..
>
> You can get a list of all the files you want with something like
>
> find /var/music -name '*.wav'
>
> You could then pipe it to xargs or include it into a for-loop if you
> expect a fairly short list.  If you expect a long list that'll cause
> memory issues, redirect to a file.
>
> I learned Perl (v4) before I really got into shell programming, but
> nowdays I do a lot of shell stuff when Perl is overkill.  Sometimes I find
> myself waffling over which is most appropriate for a particular
> application.  Often I start programming a bash script and find that I need
> to do a lot of text manipulation and convert it to Perl.  Sometimes I go
> the other way.  Recently, I even did both... started in bash, converted to
> Perl, decided that bash was actually a little more elegant.
>
> Of course, knowing the shell well helps... if you find yourself stumbling
> through shell programming but know Perl well, turning to Perl may be the
> easier solution.  But I've gotten to know the shell well enough that I
> write relatively complex scripts on the command line for one-off tasks.
> For-loops and xargs are my very close friends.  And the variable
> modification operators (#, %, etc) are good acquaintances.
>
> If you spend any real amount of time at the shell prompt, take the time to
> get to know it.  It will be worth it.
>
> --
> Carl D Cravens ([email protected])
> A man about to speak the truth should keep one foot in the stirrup.
> -- This is the [email protected] list.  To unsubscribe,
> visit http://www.complete.org/cgi-bin/listargate-aclug.cgi
-- This is the [email protected] list.  To unsubscribe,
visit http://www.complete.org/cgi-bin/listargate-aclug.cgi