InfiniteMac OSx86

InfiniteMac OSx86 (http://infinitemac.com/forum.php)
-   Leopard 10.5 (http://infinitemac.com/forumdisplay.php?f=85)
-   -   Modifying Property Lists (plist) via Terminal (http://infinitemac.com/showthread.php?t=1875)

lanceomni 01-05-2009 08:47 PM

Modifying Property Lists (plist) via Terminal
 
I am familiar with changing values in property lists via the command line. Does anyone know how you can remove all the strings in a particular part?

I use an old version of Capture One Pro and every session you start is saved in a drop down list. Removing them one by one takes some time and you can't move the plist related to Capture One into the trash as it also contains registration/activation information.

My option now would be to use Propert List Editor but id like to learn more on modifying plists from the command line.

Im trying remove all of the strings in Root/SessionRefList/SessionRefArray/

http://www.justinsligh.com/storage/osx86/plists01.jpg

Voyn1x 01-05-2009 09:10 PM

Easiest way is to use a text editor like TextMate or similar. I always use TextMate to edit plists.

Just select the lines and press delete, nice and easy :)

nfoav8or 01-05-2009 09:17 PM

or BBEdit so you keep the file permissions...

eMatoS 01-05-2009 09:19 PM

Sorry I have no clue on how to do that with the terminal, my advice, try PlistEdit Pro.

lanceomni 01-05-2009 09:26 PM

Yeah I use Smultron http://tuppis.com/smultron/ which I believe is similar. And Property List Editor does a fine job also.

I was hoping to find out how to do it via command line. Like setting Finder to display hidden files.
Code:

defaults write com.apple.Finder AppleShowAllFiles YES
I was hoping for something similar to remove all strings. I was thinking if I could do that I could create an action to do it with a single click or part of an end of the month maintenance work flow Ive set up with Automator.

I am researching the "defaults" command right now to see if I can find my answer.