Page 1 of 1

Basic question on Adiumscripts and shortcuts

Posted: Fri Aug 29, 2008 10:14 pm
by adium-tester
Hello There!

This is my first attempt at Adium Scripts and I was hoping to get some clarifications.

I downloaded a few Adium scripts and they have different shortcuts to get to them - for example, theres one that substitutes when I do a "%_bushism" and another one that substitutes when I do a "/prov". I see these phrases in the contents of the respective .AdiumScripts file - but dont know how to change this behavior. Changing the info.plist does not seem to help.

Any pointers?

Thanks,
AT.

Re: Basic question on Adiumscripts and shortcuts

Posted: Fri Aug 29, 2008 11:38 pm
by mtimmsj
This is controlled by the Info.plist file. Specifically there should be a Scripts array and each item in the array should be a Dictionary and should have a "Keyword" string that defines which commands the scripts should look for and a "File" string to define what script should be run when that string is found. It will look something like this:

Code: Select all

	<array>
		<dict>
			<key>File</key>
			<string>templatescript</string>
			<key>Keyword</key>
			<string>%_template</string>
			<key>Title</key>
			<string>Bundle Template Example</string>
		</dict>
	</array>
So in this example if someone types %_template after the Adiumscript has been loaded into Adium, the templatescript.scpt script will be run and what ever is returned from it will replace the %_template string in the chat window.

Once the plist is modified you may need to remove and readd the script for the changes to take affect.

Re: Basic question on Adiumscripts and shortcuts

Posted: Sat Aug 30, 2008 12:44 am
by adium-tester
Thanks a bunch!

I had figured out that the info.plist had to be edited and even where it needed editing - like you mentioned. I did not know I had to kill Adium and basically re-start it to make this work. Removing and re-adding the script did not help but closing and re-opening Adium did. Your post was a great pointer.

Cheers,
AT.