New answers tagged

0

I just found a way to do it. Although I'm creating an application instead of a service, they are almost the same. The basic idea is to put tell application iTerm into another script or into quotes, such that the optimization process won't make it open iTerm before executing this script. Thus you'll get the real result of if application "iTerm" is running. ...


1

What's the fully qualified pathname of the executable? If it's not within in the $PATH that's passed to the do shell script command, which is /usr/bin:/bin:/usr/sbin:/sbin, then you'll need to use the fully qualified pathname of the executable. To make an executable available globally, it must be in a directory that's included in the $PATH. You can also ...


0

Using your example, "For example: run shell command (uptime) -> speak text -> copy to clipboard" and to answer your question, "Would it be at all possible to make a task called Uptime and use one task instead of three?", yes... Simply add one Run Shell Script Action to your Automator Workflow and add the following code: uptime | pbcopy pbpaste | say ...


2

@Feanux I was answering your question and then you deleted it but I see you reposted it, anyway I have made a Automator app that does this and will attach a screenshot (that was taken by Automator). As you can see it takes two screenshots, one for clipboard and one for preview/save UPDATE:


0

Download with Description For gathering future YouTube contributions, consider downloading the files using the open source tool youtube-dl. youtube-dl can automatically put the YouTube meta-data into the downloaded file, so that it is accessible by Spotlight on OS X. As an example, the following command downloads every Global Mission of Peace YouTube ...


0

Having read through the Services Implementation Guide I'm going to have to say no to using only a shell script. If you do not want to use Automator then you'll have to create a Service using Xcode and unless you can perform that level of programming, then Automator, as slow and clunky as it may be, is looking pretty good. Just for the heck of it, I took ...


1

You can use a "Run Shell Script" action and sips to downscale your pictures to any value. Add a "Run Shell Script" action, make sure the input method is set to "stdin" (should be the default) and insert the following script SCALEFACTOR=500 while IFS= read file; do sips --resampleWidth $(($(sips -g pixelWidth "$file" | ...


4

on run {input, parameters} is AppleScript syntax, not a valid shell command. If you want to execute AppleScript in the service, use the Run AppleScript action instead of Run Shell Script.


0

This should do the trick: property parentfolder : path to home folder set theFiles to choose file default location (POSIX path of parentfolder) with multiple selections allowed repeat with theFile in theFiles set the_tags to paragraphs of (do shell script "mdls -raw -name kMDItemUserTags " & quoted form of POSIX path of theFile & " |sed ...



Top 50 recent answers are included