A message from our CEO about the future of Stack Overflow and Stack Exchange. Read now.

Questions tagged [automator]

An application developed by Apple for macOS that implements the creation of workflows.

Filter by
Sorted by
Tagged with
0
votes
0answers
14 views

Why does Automator not see new files in subdirectories on a Flash Drive?

I've created an automator app to find all the csv files on a flash drive, then modify and copy those files to a directory on the hard disk of my MAC. The automator app uses a shell script to compare ...
1
vote
1answer
32 views

Why would a python3 script not find a module when run in Automator?

I am trying to automatically run a python script using automator. This script python3 ~/Desktop/python/gmaps.py works fine in terminal but not when I try to run it through Automator , I get a "module ...
0
votes
1answer
40 views

In Automator, can I combine 2 or more variables into a new variable?

First off, let´s set the scene. I am trying to make a small applet (.app) to include in a DMG-file for distribution. The .app file will only activate when a user drags a folder with my product-files ...
0
votes
1answer
36 views

Convert image and save to same folder in Automator

I'm trying to figure out an Automator workflow (to make as a Service/Quick Action) to convert an images' file type - easy enough with the "Change Type Of Images" option. BUT, doing that alone replaces ...
0
votes
1answer
20 views

Trying to set a F8 pause/play dictation command

So I'm what one would describe as ridiculously disabled. I've recently taken a liking to using the dictation functionality due to only having the use of one hand and often having to lie on my back. I'...
2
votes
0answers
67 views

Can't run python script from Automator on Catalina “Operation not permitted”

I have a service in Automator that I pass a folder and it runs on every file in the folder. It uses a python script to read the album field from an mp3's id3 tags and write it to the Finder comment ...
0
votes
0answers
33 views

Custom Shortcut on Mac Doesn't Play Sound

I've been playing around with custom keyboard shortcuts on my Mac, and I've constructed one using Automator that is supposed to pick and play a sound from a small folder. This was achieved using an ...
0
votes
2answers
87 views

Problem with Automator/AppleScript Question

I am building a program to delete files/folders. Here is how my program looks in Automator: The problem I am having is sometimes where the program runs I get this error: The program does work so I ...
0
votes
0answers
40 views

Running “do script” synchronously in AppleScript

I have the following AppleScript that I run on login: on run {input, parameters} tell application "Terminal" do script ".../MyScript.sh" end tell return input end run I run ...
1
vote
1answer
42 views

Why automator's component “Get Selected Finder Items” duplicates path of selected file?

I'm trying to make automator quick action/service for coping text from images. It looks like this: When I run script from automator everything works fine. But when I try to run it from services menu ...
2
votes
1answer
95 views

Zip the contents of every sub-folder in a folder in Mac automatically

I have this folder/file structure parent folder --subfolder1 -sub-subfolder -file1 -file2 --subfolder2 -sub-subfolder -file1 -file2 ... I want to: create zip files from the contents of ...
2
votes
1answer
87 views

Automatically tagging files that were last opened more than x days ago

I want to set up a process to run each day and identify files that were last opened x days ago, then apply a tag like "to review" to those files. Those files would appear tagged in Finder with the ...
0
votes
1answer
87 views

How can I automate adding sender addresses to a Rule in macOS Mail? [duplicate]

So I've created a Mail Rule "Bin Spam Messages" that will delete messages from a sender. What I can't figure out is how to automate adding new sender addresses to the rule. I'm guessing I could do ...
0
votes
2answers
100 views

How to mount a disk image with automator or Applescript and without hdiutil?

An Automator workflow that mounts a disk image on when I drag and drop the dmg file onto it is easy: Instead of dragging and dropping the dmg file I want to double click the created workflow and ...
0
votes
1answer
56 views

How to automatically delete mail from specific sender?

I'm in the mail app on mac and I'm clearing out my Gmail archives and trying to speed up the process by finding senders, i.e. "verify@twitter.com" or any of the promotional ones that they send weekly ...
0
votes
0answers
15 views

How to use “New Calendar Event” Action in Automator workflow?

In Automator I can create an action called "New Calendar Event". The Name of the event can be variables but the "From:" and "to:" date are fixed values. How do I automate new calendar event creation ...
0
votes
2answers
70 views

Automator Change to directory of dropped files before running Shell command

Seems extremely simple, but I can't figure it out... I want to be able to change to the directory (folder) where the dropped file is located before running my shell script on that file. So either I ...
1
vote
1answer
51 views

How to add a timer between wget html downloads?

I found this very useful script that does the job for what I'm looking to achieve. It's been taken from this post: Batch download URLs from a .txt file To use the following method, you will need ...
0
votes
0answers
22 views

Use Single Shortcut Key to Close Windows

Some windows can be closed with ⌘+w while others require the Esc key. How do you create a single key shortcut (maybe with caps lock?) that can close both types? A built-in solution in Mojave and ...
0
votes
0answers
29 views

Automator - applescript - (condition) if X button exist then click, if not, click Y button

I am struggling with writing a script for opening up a webpage and click different buttons depending if the button itself exists. I want it to be if X button exists, then click X button. If Y button ...
0
votes
0answers
49 views

Automator script to convert webp file to JPG not working

Hi I'm trying to write a Catalina mac Automator script that will convert .WEBP files into .JPG files. The shell code in Automator I'm using is for img in "$@"; do filename=${img%.*} /usr/local/bin/...
1
vote
1answer
20 views

My mac Automator Application script is not working with two arguments

On my Catalina mac, I have this Mac Automator shell script to remove all metadata from image files as follows: for f in "$@" do /usr/local/bin/exiftool -all= "$f" done Now this utility exiftool by ...
1
vote
1answer
76 views

Set a coloured text and send it to the clipboard

This is probably very easy, but all the solutions I found were directed to specific applications. At my work, we use an online system within the browser and I find myself every day setting the color ...
1
vote
2answers
54 views

Apple Script - How do I check if a window with a specific title exists?

I would like to create an apple script that checks if a window of an application with a specific name (not id or index) exists. I used the following code in a previous script, and it works: tell ...
0
votes
2answers
95 views

Applescript - Close all windows except frontmost window

I have created an automator quick action that runs the following apple script tell application "System Events" set frontApp to name of first application process whose frontmost is true --...
1
vote
2answers
26 views

Request Applescript to copy only one file type from 2 folders, into a 3rd folder

Hi I've been trying to find utilities that will do this but I am guessing applescript/Automator on Catalina mac would work too. Basically I have 2 folders with all kinds of books (.pdf, .mobi and ....
1
vote
1answer
40 views

How do I save a text file using a variable using the “New Text File” action in Automator?

I am new to Automator and writing with AppleScript. I wrote a program that collects URLs and stores them as a long, single string. After the AppleScript portion of the workflow, I want to save the ...
0
votes
1answer
35 views

Pass parameters upon invocation of Applescript

I am writing an applescript to automate some iterm-related repetitive tasks. I need to find out what is the appropriate way of accessing parameters from the script, say as in on run {input, ...
1
vote
1answer
20 views

AppleScript: Failure to create new iTerm2

I have the following AppleScript code in a Run AppleScript action in Automator: on run {input, parameters} set appName to "iTerm" if application appName is not running then tell ...
1
vote
0answers
18 views

How do I store an automator action in version control (git)?

I just created an Automator 'application' action and it works fine but I want to have version control of it. Automator creates a bundle that seems to be a bunch of XML and resources which is a pretty ...
0
votes
0answers
50 views

Use Nora Siri voice for mp3 Conversion MacOS

Model Identifier: MacBookPro11,4 System Version: macOS 10.15.1 (19B88) macOS Catalina recently made the new "Nora Siri" text to speech voice available for normal use. In the past, the voice would ...
7
votes
4answers
809 views

How to prepend a character to start of each line in 250,000+ line file using a script?

I have text file with 250,000 lines - and I need to append the same single character at the start of each line. I have tried to use various multiline /column edit plugins in Atom and Sublime but they ...
1
vote
0answers
12 views

How to scan for visible Airdrop devices via Applecript?

I'm trying to figure out a way to scan for nearby airdrop devices and display a list of them but I've had trouble finding relevant examples or documentation. Can anyone point me in the right direction?...
0
votes
0answers
25 views

Script for creating new Mail message

I would like to do the following with some kind of automation (Automator, AppleScript, Alfred Workflows, whatever works): Create a new email with the following filled-in: From a specific email ...
0
votes
0answers
20 views

Can't automate typing in Safari with AppleScript when Safari is not the current window

I've searched all over the web but can't seem to find an answer to this. I developed this applescript to type in safari with the intended purpose for it to keep typing in the background while I worked ...
1
vote
1answer
66 views

How to remove metadata from image files using AppleScript?

I am using Catalina. I want to create an application using Applescript which which will remove metadata from dropped image files (onto its icon) using the unix utility exiftool. I tried the following ...
3
votes
1answer
90 views

Automator - Shell Script - ffmpeg: image sequence to video

Terminal can generate video from PNG seguence (0001.png, 0002.png, ...) via ffmpeg: ffmpeg -i %04d.png -r 24 -codec prores output.mov But how can I tell ffmpeg use for input image sequence in ...
1
vote
1answer
42 views

Watch Me Do or other method for exact pixel coordinate of mouse click (Automator)

Is it possible to specify how a mouse click point is recorded or processed in Watch Me Do? had thought it was exact pixel position recorded but it seems that in a safari browser it is relative to ...
2
votes
1answer
46 views

apply a terminal conversion command to each file in a folder

How do you apply this terminal command ffmpeg -i $f -ac 2 -codec:a libmp3lame -b:a 48k -ar 24000 -write_xing 0 $f_converted; to every file in a directory? ($f is the filename and $f_converted is the ...
0
votes
0answers
29 views

Automator - is it possible to repeat Watch me Do for each clickable div element in a div list on a webpage

I'm trying to have automator click on a series of div buttons that have the same html structure in a long table-list (actually divs) on a webpage. (after clicking each one, do the same thing click on ...
0
votes
0answers
19 views

Creating an Automator workflow which inputs any selected text if present, but will still run if there is no text selected

I'd like to set up an Automator workflow which if run when there is some text selected, will perform a Google search on that selected text. But if there is no text selected, then the workflow should ...
3
votes
4answers
239 views

How can I automate repeat mouse clicks, with delay, from fixed coordinates within a browser window?

Looking for a quick and dirty way to automate this mundane activity. I presume this could be done with an automation to press the mouse button from two separate pixel coordinates, with delay, so long ...
3
votes
1answer
127 views

Automator action to run python script on series of files fails in Catalina

Major edit I've just discovered that the Automator workflow I'm having problems with works perfectly if I run it by pressing 'play' in the Automator window, and it seemingly only fails when I save it ...
1
vote
1answer
33 views

How to use selected text in apple script? I want to add text before and after it

Idea: I select text, and it gets replaced with <sometag>selected text</sometag>. Code: on run {input, parameters} tell application "System Events" to keystroke "<tag>[what should ...
1
vote
0answers
26 views

How to create Automator workflow to paste in authentication code within a GUI app?

I currently have created an automator workflow (in Catalina) that will paste in a two-step authentication code by a keyboard shortcut within the Cyberduck app. However, I am wondering how to possibly ...
4
votes
1answer
333 views

macOS Catalina causing “find: .: Operation not permitted” errors

I have an automation workflow that I use as a Quick Action. It takes a Finder item and calls a shell script with it. Part of the shell script runs a find command on the directory of the Finder item. ...
0
votes
2answers
25 views

How to activate an Automator application with AppleScript?

Why does this fail to open the application? try open application "Macintosh HD:Users:TheUser:Desktop⁩⁩:Automator test 2" on error display dialog "could not open the automator" end try I've ...
1
vote
1answer
51 views

Mojave doesn't remember window position/size for a specific application?

Normally on Mojave all applications windows settings are stored automatically. Still I have one program which does not do this, every time I re-open this app I have to maximize (not full screen) it's ...
1
vote
0answers
60 views

Batch compress contents within a folder using Mac Automator

I've seen an automator service that can zip multiple folders into separate zip files: Batch compress multiple folders into individual zip files Can this be modified to enter the folder, compress the ...
1
vote
0answers
23 views

Can Automator open a generated Google Doc?

I have an Automator that copies a Google Doc file from one folder into another one, and then rename it to something different (the name varies). I'd like Automator to open the newly renamed file, but ...