Jump to content

The official custom AppleScript thread.


22 posts in this topic

Recommended Posts

Here's one to kill the Finder on startup and make it easier to surf your Mac using the Terminal.

 

Let me know if the enabler actually works, though, because if not, I need to change the script. The restart command is a legacy command and I'm not sure if it will absolutely work or if will give you a "can't do it" error.

 

OK, made one other change, which is just a name change. Everything else is the same, but the new name is more indicative of what it does.

TerminalSurf.zip

Link to comment
Share on other sites

Moose, Damned Script just shows the power of OSX. If something like that would have run in Windows, it would be dead.

 

For proof try this

 

Goto C:\ -> New Text Document -> Type in Call A.bat (Try Call A if this doesnt work) -> Save -> Rename New Text Document to A.bat. -> Click A.bat and see Windows Crash and Burn.

 

NOTE: You Must have "Hide File Extensions Of known Filetypes" Disabled for this to work.

Link to comment
Share on other sites

Here's another basic script that I made.

Try it on your friends and tell them that it's an update or something. ;)

It opens most of the basic Mac apps one after another continuously. Some of the apps that it opens are from iLife '06, so make sure that you have that too.

open.zip

Link to comment
Share on other sites

  • 1 year later...

I made a ton of scripts...

 

-"OCD My Windows" is a fairly easily moddable script, tat when run, puts the windows of all the stuff I usually have open into it's place. But I don't give that one out to anyone...ask my privately if you want it.

 

-"Auto Reply Bot" AKA CarterBot is a huge script for the Leopard version of ichat. It has a huge list of text triggers that anyone you're talking to can say, and it will react instantly with a programmed or random answer. Again, also by request only...

 

-"Change Play Count" is a short script for iTunes that allows the user to edit the selected song's play count...that will be available in the next version of xMod, so I'm not giving out the script file just yet.

 

I have written bunches and bunches for my application, xMod, and even more just for my convenience. I consider myself an AppleScript and AppleScript Studio master, so if anyone needs a custom script, just let me know!

Link to comment
Share on other sites

  • 4 months later...

Here's one I just made. It opens the Finder to where the intro movie/sound clips are stored so you can copy them to anywhere you like. (or just see/listen to them)

Get_intro_Movie_Sound.app

 

Have fun! :lol:

 

Ok, got a new one. This little handy tool gives you 3 options (Restart Finder, Restart Dock, and Empty Trash).

Simple_Utilities.app

Link to comment
Share on other sites

  • 5 months later...

Hi all,

 

I'm after an Applescript which will launch automatically as a login item, wait for 5 minutes then restart the Mac without the need for user intervention.

 

The reason I want this functionality is to test machines which have intermittent kernel panics. These are often related to the Airport Extreme card or the ATI graphics chip and occur most frequently on startup. You sometimes need to restart the machine by hand for hours so a script which allowed the machine to boot, pause and then restart automatically would be really useful.

 

Can anyone help?

 

Thanks,

 

David

Link to comment
Share on other sites

  • 2 weeks later...
  • 3 weeks later...
  • 11 months later...

I am having trouble with an Applescript app Im making. I have it set up to run a script on launch to find the disk number, and pass that as a property. Here is the code:

 

property diskNumber : {}
property listOfDisks : every word of (do shell script "diskutil list | grep EFI | grep -o -e disk[0-9]s[0-9]") as list

on launched theObject
if (number of items of listOfDisks) is greater than 1 then
	display dialog "Multiple EFI partitions have been found.
			Please choose a partition:" buttons listOfDisks
	set the button_pressed to the button returned of the result
	set diskNumber to the button_pressed
else
	set diskNumber to item 1 of listOfDisks
end if
log diskNumber
end launched

The problem is that when I launch it, it just throws an applescript error: No result was returned from some part of this expression.(-2763)

 

No display dialog ever comes up or anything. Any ideas why this isn't working?

Link to comment
Share on other sites

  • 5 years later...

Hi everyone,

 

I have searching high and low through various mac forums and have been somewhat unsuccessful in reaching my goal. What I'm trying to achieve is have an automated process on my iMac (Mid 2010 - Core i3 - 16Gig RAM - Mavericks 10.9.5) which will change the folder's icon as it is dropped onto the Automator applet. The principle I had in mind is that, as the movie folder is dropped onto the applet, it will take a generic file called either folder.jpg or poster.jpg, then convert the image into an ICNS file and finally take the ICNS file and make it the folder's new icon. This process is to also be looped, meaning to scan all sub-folders and if a JPG is present to use it for that same named corresponding folder. All files and folders in question located on a ReadyNas Duo V2 with guest access and full R W X permissions. I'm aware of the manual process which is to right click on folder and select get info, then simply drag the poster.icns file onto the folder in the top right of get info window. Really wish it could be automated.

 

From the screenshot, you see what I'm trying to achieve. For now I have found a couple scripts (found online) which allow me to retrieve movie.xml and Cover information online and save these in their respective folders. Now that Covers are downloaded as JPG files named as the movie folder. I would hope that there is automated process which can assist at changing multiple folder icons.

 

Any help or guidance would be greatly appreciated. If anybody is able to assist, I can post the AppleScript that I have started working on for further analysis.

 

Ps if this post is in the wrong area, please advise, I'm a noob here.

 

Thank you in advance. Have a great day all

Dud3m@n

 

iMac, OS X Mavericks (10.9.5)

post-1453458-0-44962000-1441107696_thumb.jpg

Link to comment
Share on other sites

 Share

×
×
  • Create New...