[talk-au] Simple linux shell script for batch processing

Ross Scanlon info at 4x4falcon.com
Sun Jun 21 15:20:58 BST 2009


Hi All,

Following on from the discussion on anonomising gpx files here's the basis of a shell script which will process all files in a directory or all subdirectories in a directory.

------------------ cut here -----------------
#!/bin/bash

#uncomment one of the following directory commands to use this

#use this to process all files with extension .tif
#you can change this to suit 
#for file in $( find $directory -type f -name '*.tif' | sort )

#use this to process all subdirectories in a directory
#for file in $( find $directory -type d  | sort )

do

#this is where the command goes that you want to act on all files
#at the moment it just echos the file name

 echo $file

done
------------------ cut here -----------------

Now if I could just work out the exclude polygon filter for gpsbabel.

-- 
Cheers
Ross




More information about the Talk-au mailing list