automator

AppleScript: adding mounted folder to Finder Sidebar?

最后都变了- 提交于 2020-01-24 15:51:47
问题 I have a simple Apple Script that mounts a folder: mount volume smb://machineip/folder This runs on start up since Mac OS X 10.5.5 doesn't have the concept of mapped drives like Windows. The script doesn't go as far as I'd like though. I get the machine IP added to Finder Sidebar and when I click it, all of the shared folders for that machine appear, including the above "folder" with the little eject icon. How do I get that folder to appear under "Devices" in Finder Sidebar using Apple Script

Mac Automator - Combine PDF files, save in same folder

元气小坏坏 提交于 2020-01-10 11:46:12
问题 I'm using Automator to combine PDF files, but can't figure out how to automate saving the resulting file to the same folder. (Instead, it asks me where to put the file.) I'm using it as a service - here's my existing workflow: 1) Service receives selected -PDF files- in -any application- 2) Combine PDF Pages [appending pages] 3) Rename Finder Items: Name Single Item [Name Single Item, Basename only, to "TestResults"] 4) Move Finder Items [to a folder - show action when workflow runs] Ideally,

AppleScript access Network Folder

孤者浪人 提交于 2020-01-04 12:49:20
问题 I'm trying to make a backup of a folder on our network to my Desktop but I'm not sure how to access the folder on the shared network. My code is as follows: on run {input, parameters} set desktopFolder to "Macintosh HD:Users:James:Desktop:App Backups:" set todayDate to do shell script "date '+%Y.%m.%d'" set newFolderName to "Backup " & todayDate set destinationFolder to desktopFolder & newFolderName set sourceFolder to "smb://svr01/IT_Department/Design/_team/James/App" tell application

AppleScript access Network Folder

让人想犯罪 __ 提交于 2020-01-04 12:49:07
问题 I'm trying to make a backup of a folder on our network to my Desktop but I'm not sure how to access the folder on the shared network. My code is as follows: on run {input, parameters} set desktopFolder to "Macintosh HD:Users:James:Desktop:App Backups:" set todayDate to do shell script "date '+%Y.%m.%d'" set newFolderName to "Backup " & todayDate set destinationFolder to desktopFolder & newFolderName set sourceFolder to "smb://svr01/IT_Department/Design/_team/James/App" tell application

Applescript - Creating folders based on the first word of the filename

放肆的年华 提交于 2020-01-03 05:04:19
问题 Essentially i'm looking for an applescript that allow me to order the massive 50.000 files by creating folders that have just the first word of the files, ignoring the rest of the filename after the first space. For eaxmple the 50.000 files are named like this: - amazingfrog -shootingbase.jpg - frog 2sHDn1_9fFs12s.jpg - frog 29adjjdd39939.mov - Horse IUS39aosdja.mov - horse 282131888.jpg - HORSE.jpg And so on..... - I would like to be like this: - amazingfrog -amazingfrog -shootingbase.jpg -

How to automate extracting pages from a PDF using AppleScript and Acrobat Pro?

风格不统一 提交于 2020-01-01 16:53:51
问题 I'm new to AppleScript, but I am trying to create a script that will go through all PDFs in a folder extracting the pages into separate files. My plan is to use a combination of Automator and AppleScript. My AppleScript so far is: tell application "Adobe Acrobat Pro" open theFile set numPages to (count active doc each page) --execute the extraction here end tell The command in Acrobat Pro is under Options > Extract Pages... , where I can specify the page range and to extract to separate files

How to automate extracting pages from a PDF using AppleScript and Acrobat Pro?

删除回忆录丶 提交于 2020-01-01 16:53:29
问题 I'm new to AppleScript, but I am trying to create a script that will go through all PDFs in a folder extracting the pages into separate files. My plan is to use a combination of Automator and AppleScript. My AppleScript so far is: tell application "Adobe Acrobat Pro" open theFile set numPages to (count active doc each page) --execute the extraction here end tell The command in Acrobat Pro is under Options > Extract Pages... , where I can specify the page range and to extract to separate files

Editing text in Automator

北慕城南 提交于 2019-12-31 02:31:26
问题 I'd like to create an Automator service that can take the seletced text and replace it with an edited version. i.e. The selected text will be something like "this is selected text". The output will then take that text and output something like... "Some predefined beginning(this is selected text, this is selected text)" I have done similar things with file names before but nr=ever with actual text. Can someone point me in the right direction please. Thanks 回答1: Choose Service as you Document

Applescript: Create folders/subfolders and move multiple files

一曲冷凌霜 提交于 2019-12-30 13:34:10
问题 I have an Applescript question that is much more complex than I can construct. I have been searching for the past couple of days, and I cannot find any script like this, nor can I find enough information to piece one together with my limited knowledge. I have multiple files with structured names. Each file has the following name structure: ttu_collectionname_000001.pdf ttu_collectionname_000002.mp3 ttu_collectionname_000003.pdf ... etc. (Each of these files are of varying file types.) There

Automator not working inside xcode

假装没事ソ 提交于 2019-12-25 09:15:25
问题 I am running an automator with an applescript, and while it works inside automator, it fails when run from xcode. Here's my code: tell application "Xcode" set targetProjectPath to path of active workspace document set targetProjectPath to POSIX file (targetProjectPath & "/..") as string set targetProjectPath to POSIX path of targetProjectPath tell application "System Events" tell process "Xcode" click menu item "Save" of menu 0 of menu bar item "File" of menu bar 0 end tell end tell return