So the $1+0 actually adds the initial number on the line? If it was 139ab5, $1+0 would be 139? It just goes through and changes n each time it encounters a number, stops at each . and then when it gets to the end, TOTAL does nothing? So watching n as it went through, it would be "0" for the first 7 lines, then it would proceed through each integer, 1-18, and remain at 18 for the last line?
Correct.
The idea in this case is to set n with each successive leading number. It assumes that the numbers as presented by the source will increase. It is a bit tricky, and a more obvious way of writing it might be along these lines:
You'll find with awk there are lots of ways to do the same thing.
Ok... so here is what I have for the ripping:
This rips to a .wav specified by $1, converts it to an mp3, deletes the .wav then advances the tempo of the .mp3 by 1.4x and saves both .mp3s.
So what I was hoping to do was to automate things a bit and call this as a subroutine in a script that would auto rename the files as I ripped each disc. I think I got it working with this:
unfortunately, if I want to use my standard format for file names which is "Title -- Disc ##.mp3", I can't get it to work with
Forgetting of course that I haven't updated the second while loop for an input such as Freddy and Fredericka as my $1.
a) what can I clean up from my first attempt at sequentially numbering file names and
b) how can I get it to use the $1 of something like Freddy and Fredricka ?
c) how do I put my ./rip script in as a subroutine and call it? just name it and put it in {}s?
Just finished this Audible audio book. It's simply great.
Highly recommended:
This book was so well done that I did not want to miss a single word; so ended up listening to half of the book twice when I got distracted. This is a great audio book.
... (0 Replies)
This is a DEMO shell script to generate a simple graticule and plot inside it...
Apologies for any typos...
it is another building block along with my other two shell uploads recently to start a semi_serious project of an Terminal_AudioScope...
The fist upload I posted recently was to show... (83 Replies)
I have a lot number audio files in the MP3 proprietary format, I want to convert them to 'opus' the free and higher quality format, with keep metadata also.
My selection command-line programs are SoX (Sound eXchange) for convert MP3 files to 'AIFF' format in order to keep quality and metadata*... (1 Reply)
This site is the first to get this snippet.
It will capture an audio recording of any time length within the limits of OSX's QuickTime Player's capablility...
A shell script derivative of this will be used as a further capture for CygWin's AudioScope.sh.
Thoroughly read ALL the comments in... (0 Replies)
I'm trying to record audio using Audacity 2.0.5 installed from SlackBuilds. My system is 64-bit Slackware 14.1 and a sound card is Intel HD Audio. I didn't change my sound system to OSS. (Default sound system in Slackware 14.1 is ALSA, isn't it?) First, I set Internal Microphone slider in KMix... (2 Replies)
Good evening, I'm currently working on a BASH script to convert audio between file formats and I've come across a snag. At the beginning of the script, I'm having the system check to see if any files with the .m4a extension exist in the directory, and if so, it runs the script. If there are no... (1 Reply)
I am having following folder structure.
/root/audios/pop
/root/audios/jazz
/root/audios/rock
Inside those pop, jazz, rock folders there are following files,
p1.ul, p2.ul, p3.ul, j1.ul, j2.ul, j3.ul, r1.ul, r2.ul, r3.ul
And I have a file named as "audio.txt" in the path /root/audios,... (11 Replies)
Hi
i am new to UNIX completely. i dont know any thing about UNIX.
can some one please help me with some books on the unix archetecture and all the internal working of UNIX OS (i want to know every thing about unix from basics) and shell programming.
can any one please if available provide... (1 Reply)
Hello,
I'm still learning unix and I have what is probably a simple question but I can't seem to find the question to. I have an Ultra 10 Sparc Server running solaris 8 and the drive may have crashed (I hope not). Currently, it appears some files in the /etc folder are missing. I have a backup... (1 Reply)