AppleScript is the Mac OS scripting language.

learn more… | top users | synonyms

1
vote
1answer
1k views

Mouse movement vertical axis inversion? (Mac OS X)

I would like to either run an AppleScript or use a Terminal command to invert the y-axis for mouse movement in OSX— and no, not like http://d.pr/w9z7 (/joke). Any ideas? I thought about checking for ...
1
vote
4answers
4k views

Applescript save command for QuickTime Player

I've installed the Perian addon for Quicktime so it can open .flv files, and then I can save them as .m4v or .mov. I'm trying to make an Applescript to convert from .flv to .m4v automatically by ...
1
vote
1answer
113 views

Cron jobs and clipboards

Pbpaste doesn't seem to work as expected when I run it from a cron job. I have an applescript that opens a PDF file in Preview and sends it the copy command and then closes Preview. Next I'd like to ...
1
vote
0answers
123 views

Desktop Picture Placement

I made an Automator app that changes the desktop picture to whatever image file you drop on its icon. It used to work perfectly until Snow Leopard. Now the image placement always resets to Full ...
2
votes
2answers
390 views

Trying to silence Terminal Applescript

I have an Applescript that changes directory for the front Terminal window to the front Finder window. It works fine, but it also outputs text which clutters my terminal window. Does anyone have any ...
1
vote
3answers
304 views

Is there a way to avoid having to click Autofill in iTunes?

I'm tired of always having to click "Autofill" in iTunes to put new songs and podcasts on my second generation iPod shuffle so I'm looking for a way to automate this with a keyboard shortcut, ...
3
votes
1answer
1k views

How do you send the “ESC” key in OS X using osascript

I'd like to create a small script using osascript in Mac OS X Snow Leopard to emulate pressing the Escape key on the keyboard. How is this most easily done?
8
votes
2answers
4k views

Applescript to open a NEW terminal window in current space

Yes, I'm having a terrible newbie experience with Apple Script. I need to open a new Terminal window in the current desktop space. NOT move me to another space which has a Terminal running and then ...
1
vote
0answers
167 views

process pdf attachments with applescript and pdfpenpro

I've set up a gmail account that will contain nothing but emails with pdf attachments. I've also set apple mail up to check this account. Now, I would like to set up an applescript to take the pdfs ...
1
vote
2answers
282 views

Is there a way to stop iTunes after the currently playing radio song ends?

While scripts like This Is The Last Song and Just Play This One work great with local songs, they don't seem to work with Internet radio stations like Groove Salad in spite of the fact that the name ...
0
votes
0answers
579 views

Script Mail.app to auto-save attachments?

In similar thinking to a previous question, is it possible to script Apple's Mail.app to auto-save attachments from a given address or file type? Presuming it is, what would that AppleScript look ...
2
votes
1answer
676 views

How do I create a Genius playlist in iTunes 10 from a script?

I want to create a script that starts a new Genius playlist based on the currently-playing track to use in LaunchBar. Unfortunately iTunes doesn't expose any Genius-related functionality to ...
0
votes
2answers
2k views

self-closing applescript

so I'm totally new to applescript.. basically I want my applescript.app to run a shell script then exit do shell script "/usr/local/groovy/bin/groovyConsole" the above script opens groovyConsole ...
5
votes
1answer
1k views

Determine Mac's screen state using AppleScript

Is there a way to determine what state the Mac's screen is in? I'd like to have a script that checks if the screen is in a non-active state; so either the screen saver is running or the display is ...
1
vote
2answers
611 views

Add Secure notes to Keychain via Applescript

I have switched from Windows to Mac and one of the things I need to set up properly is password management. Previously on Windows I was using a small TrueCrypt file containing text files with ...
4
votes
1answer
564 views

AppleScript Editor record doesn't work

I have opened the AppleScript Editor and pressed Record button. Then I run TextEdit, create a file and put some text there. When I click Stop button in AppleScript Editor, nothing was recorded, the ...
2
votes
1answer
2k views

How do You Open the Contents of a Folder with AppleScript?

I am currently using this UNIX shell command in my script file: do shell script "open ~/Dropbox/Media/VisionBoard/*" Is there another way to do it and if so would it be any better or different? ...
0
votes
1answer
212 views

Set “Away” Status on Several Apps at Once

This question is slightly born out of laziness, but here goes anyway. I use the following apps on OSX: Skype Adium Linkinus On each, I have an automated status change that triggers after being ...
2
votes
1answer
896 views

Is there a way to use AppleScript to create an iCal alarm that runs AppleScript like you can manually?

All I see in iCal's dictionary are display, mail, sound, and open file alarms. Note: I know I can save the desired script as an app and create an open file alarm, but that would mean that the alarm ...
3
votes
1answer
1k views

How can I run a script whenever I plug in an external monitor? [duplicate]

Possible Duplicate: Reset Mac OS X Windows Position after de-attaching external monitor I use my laptop at work, where I have a second monitor, and at home, where I don't. When I plug in ...
1
vote
2answers
865 views

How do I escape a slash in AppleScript?

How do I escape a slash in AppleScript? The documentation seems to suggest that set target_string to "\\" should return a single \, but in fact it returns \\\\. On the other hand, set ...
0
votes
2answers
1k views

Inserting Keynote slides into a Pages document

I have a number of training documents which are formed from a word processor file and a slideshow. I'd like to be able to keep them together, ideally by inserting the slides from Keynote into Pages. ...
0
votes
2answers
2k views

AppleScript and Preview.app

I saw this post: http://superuser.com/questions/155517/how-do-i-get-applescript-to-work-with-preview-in-snow-leopard In my attempt to figure out how to use AppleScript with Preview. I'm trying to ...
1
vote
1answer
1k views

How to get QuickTime Player 7 to save its export settings?

I'm trying to get QuickTime Player 7 on Mac OS X 10.6.4 to save its export settings so I can batch convert some MKV movies to M4V (MPEG-4). I've already exported a movie using the settings I want. ...
0
votes
1answer
371 views

Bundle applescript into application from the command line

I can compile an applescript file into an application from the applescript editor, but I would like to be able to do this from the command line. Does anyone know how I can do this?
0
votes
1answer
2k views

How do I get applescript to work with Preview in Snow Leopard?

How do I get applescript to work with Preview in Snow Leopard? I'd like, for instance, my applescript for resizing a window to full screen (which works for most applications (e.g., chrome)) to work ...
1
vote
1answer
201 views

What are the pros of using Path Finder?

What are the pros of using Path Finder, and not Finder? Could I not get some of the features of Path Finder by adding Applescript scripts to the stock Finder?
20
votes
3answers
16k views

Assign a shortcut to running a script in OS X

Does OS X provide an easy way to bind key combinations to commands which are typically run on the command line? For example, is there some way to assign ⌘ Cmd+L as a global shortcut for ...
2
votes
1answer
582 views

Different Wallpaper if two monitors are attached

I am working on my MacBook Pro. In the office I have 1 27" Monitor attached to it, at home I tend to work without an second monitor. For that setup I want to change the wallpaper if no 2nd monitor is ...
0
votes
1answer
406 views

iDVD Random Transitions

I am creating a dvd slide show using iDVD and I see how to add transtions manually but what I would like to do is have iDVD insert random transitions for me. Is this possible?
1
vote
3answers
2k views

How to assign shortcut to applescript per application or how to show per application scripts menu

There are applications which have script icon in menu like iTunes, NetNewsWire, TaskPaper and it is easy to create script for those apps and assign shortcut (using Keyboard pref pane), but most don't ...
1
vote
1answer
335 views

applescript: establish PPPoE connection

how would an Applescript look like that connects to a specific PPPoE configuration? i want to trigger this via Launchbar. (or a more fancy script which checks if the current chosen network location ...
1
vote
1answer
2k views

How to automatically print the contents of a folder in OS X?

I would like to be able to set up a folder on my Mac, where I could dump files and have them be automatically sent to the default printer. This way I would be able to print files at home when I'm not ...
3
votes
1answer
2k views

What is the best way to make Calculate SHA1 as a context menu option in Mac OS X?

In order to calculate the SHA1 checksum of a downloaded file, I could type /usr/bin/openssl sha1 in Terminal and then drag there the file which I want check. To make it simpler, one could enable a ...
0
votes
2answers
620 views

Applescript cannot find sed during application install

I am attempting to install an application, but the installer fails with the following error message: sh: sed: command not found and there is an Edit and OK button in the dialog, so I click the Edit ...
0
votes
1answer
760 views

Excel; exporting/importing different columns to different csv files

Is there a way to batch export different columns to different csv files in excel on an OSX, I'm thinking something along the lines of possibly automator, applescript or bash. I've had a look play ...
1
vote
2answers
2k views

how can I save the layout of my open apps on osx?

I'd like to save the position and size of my open apps and restore them later (after restart). I found an applescript that does this with finder windows only: ...
3
votes
1answer
1k views

How to update Preview.app from the command line without losing focus on Mac OS X?

I want to update Preview.app in the background from the command line without losing focus of my current window. I know that I can use the following to open/update the view of a file, but then I lose ...
5
votes
2answers
1k views

How do I make Mail.app quit after iCal sends an alert?

iCal uses a built in script file to email reminders through Mail.app. It works great, but I don't use Mail.app for my main email account, just for sending calendar notifications. So, Mail.app opens ...
2
votes
1answer
815 views

Save as PDF to Folder Script for Apple Mail

I want to add a script to a rule to auto-print messages as PDF to a specific Folder. What I found was this: http://is.gd/acmsE but it doesn't work for me on OS X 10.6. I already know the Save to PDF ...
1
vote
3answers
1k views

Can Automator or Applescript copy the number of items in a folder to the clipboard?

In Automator or Applescript, is there a way to get the number items in a folder and save result to the Clipboard or Automator Variable so I can use it in the next Action?
2
votes
1answer
982 views

Save and reopen Spaces configuration in Mac OS X

Let's say that I am working using several spaces. In one of them I have 20 applications opened with their respective files. My computer crashes and I have to open everything again. Instead I want to ...
4
votes
2answers
1k views

Mac Screenshot of a Specific Window without Using the Mouse/Click

I've been researching for a day or two but can't find a method to take a screenshot of a specific window (possibly the only window) open at a specific time using an Apple script. Currently I have the ...
2
votes
1answer
81 views

Are Snow Leopard text substitutions scriptable?

I prefer using typographical quotation marks when possible, so I love the Smart Quotes part of Snow Leopard’s text replacement feature. But there are a few cases in which I need to toggle it, and it’s ...
8
votes
7answers
4k views

MacOS X: How to have a handy “Open this folder in iTerm” shortcut?

I think the title states exactly what I want to do. I want a shortcut or even a button within Finder which fires up a new iTerm Tab and changes the location to the location i've open in Finder. Some ...
0
votes
1answer
283 views

Add Feeds to Mail.app from the Command Line

Is it possible to add (RSS/Atom) feeds to Apple's Mail.app without using its GUI? It's possible to subscribe to feeds using Mail.app through Firefox but I don't know how they implemented it (you ...
3
votes
1answer
247 views

Script Editor in Snow Leopard painfully slow after adding apps to Library

I have four different Macs that I use from time to time, and on each of them I notice a constant: adding more items to AppleScript Editor's Library window slows performance of mundane operations ...
0
votes
1answer
374 views

Applescript - Take a plain text and turn into a html link

We work with bugzilla. Whenever you need to query a ticket you just need to know the bugid (integer) and you simply prepend this to it. ...
3
votes
4answers
4k views

Applescript to lock the screen

I need a little Applescript to lock the screen, the same behaviour I get when I click the Keychain icon in the menu bar and choose "Lock screen". I found a way to activate the screensaver, but it's ...
2
votes
3answers
1k views

Get a list of all files and their attributes on OS X

What is the best and fastest way to get a list of every file on OS X including hidden and system files along with their attributes? I'm not afraid of the terminal or scripts, but if there is a ...