AboutWelcome to Free Software Daily (FSD). FSD is a hub for news and articles by and for the free and open source community. FSD is a community driven site where members of the community submit and vote for the stories that they think are important and interesting to them. Click the "About" link to read more...
One of the most common structures in programming is the Do Loop. The version that I’m going to show today is the While Do Loop. This post shows how to use the basic structure of the While Do loop in a Bash script.
Let's say you have a directory with hundreds of files with the wrong file names, and you'd like to replace every filename containing test with prod. (this is a contrived example). We can easily do this with the "for" command in bash, combined with a little bit of bash goodness. Today we'll learn how to replace text in a variable in a for loop.
The Bash Debugger Project (bashdb) lets you set breakpoints, inspect variables, perform a backtrace, and step through a bash script line by line. In other words, it provides the features you expect in a C/C++ debugger to anyone programming a bash script.
In this second and final part I'll demonstrate some of the loop-specific tools I've found in Ardour, Reaper, and Audacity. Tutorials and links to project demos are included, so warm up your headphones and let's get loopy.