Hi all,
Some time ago I got some great help from this forum, and I hope this will happen again, because I’ve got something else which I want to achieve and I don’t really know how.
The thing I wanted to do earlier was to open all “English.lproj” folders recursively, starting from a certain folder. Some of these folders are buried inside package folders. The final script looked something like this.
global myFileList
on run
set myFileList to {}
set theFolder to choose folder with prompt "Please select a folder..."
tell application "Finder"
activate
end tell
parseFolder(theFolder) of me
end run
on open this_item
parseFolder(this_item)
end open
on parseFolder(aFolder)
do shell script "find " & quoted form of POSIX path of aFolder & " | grep English.lproj$"
set myFileList to the result
set myFileList to myFileList's paragraphs
set AppleScript's text item delimiters to "';open '"
set myFileList to "open '" & myFileList & "'"
set AppleScript's text item delimiters to {""}
myFileList
do shell script myFileList
end parseFolder
I would now like to have a script that does something similar but the problem is a little more complicated. Some English.lproj folder contain nib files, which are really package folders, and which contain 3 files usually (objects.nib, classes.nib, info.nib). What the script should do is open all nib files inside English.lproj folders which obey a certain condtion. The condition would be that the info.nib file inside the nib file contains a certain string.
May be this is too much to ask, but I’m trying anyway, because such a script would be really useful to me. Maybe someone can put me on the right track? Many thanks!!