Tagged Questions
2
votes
3answers
120 views
look up a word in Dictionary.app in Terminal
Is there a bash or applescript to look up a word in /Applications/Dictionary.app from a Terminal window ?
open -a /Applications/Dictionary.app/ --args word
ignores --args, says "type a word to look ...
6
votes
3answers
154 views
How to add folder to Spotlight “do not index”?
Is there any way to programmatically add a folder to Spotlight's "Privacy" tab?
Either through Terminal or Applescript?
Often I want to click on an item in Spotlight results in Finder, and have that ...
1
vote
4answers
323 views
How can I create a stand alone APP to run a terminal command
I have the requirement to manually run the OSX maintenance scripts in OSX (Lion / Mountain Lion). I would like to create a completely stand alone application that would achieve the following goals:
...
2
votes
2answers
129 views
Using cURL to download images in XML feed?
I have an XML file that has links to various .jpg I want to create an applescript that downloads a local copy of these. The idea is to also label them sequentially with a number say 001 to 030.
...
0
votes
0answers
66 views
How to add a script that types in the password for my vps through applescript
I made a script recently and have turned it into an app, it basicly logs me into my vps via ssh but I don't know how to tell it how to type in my password for me, heres the code
tell application ...
1
vote
2answers
207 views
Automatically move files into correct folder on server
I often need to move files from one location on a server into a set of hierarchical folders.
The filenames are usually 7 digits long - sometimes with some extra characters at the end.
The folders ...
0
votes
1answer
141 views
Programmatically read both per-tab Terminal.app titles
When bringing up the Inspector (⌘I) in Terminal.app to edit the title (⇧⌘I), there are actually two titles that can be entered. The first is known as the Tab Title and affects the terminal window ...
4
votes
1answer
208 views
Any way to write the Terminal scrollback history?
I would like to open a new tab in Terminal with custom scrollback history. The primary use-case is to "fork" an existing tab such that both tabs contain the same scrollback history, but more generally ...
1
vote
1answer
147 views
How to start an app in the foreground?
For some reason, gitk always starts under all other apps.
How to make it start on top of all other apps, like a normal program?
Start it from the terminal with the gitk command, which lives in ...
0
votes
2answers
226 views
How can I connect Linux server with Applescript using iTerm or Terminal?
I want to connect and run bash script on Linux server automatically by using Applescript and iTerm or Terminal on OS X.
How can I connect Linux server with Applescript use iTerm or Terminal?
29
votes
3answers
12k views
How can I trigger a Notification Center notification from an AppleScript or shell script?
I'd love to be able to take advantage of 10.8's Notification Center features in AppleScripts and shell scripts I write.
Is there a built-in command or a third-party library I can use from either an ...
0
votes
1answer
116 views
Applescript to monitor terminal changes
I want to be able to check if a word appears in a terminal window running a java application and then display a notification. Any ideas?
0
votes
1answer
170 views
pasting commands from TextWrangler to Terminal (applescript troubleshooting)
I have a following script that I have been using for years to paste selection or a whole line from TextWrangler to R. I got it from some website, slightly modified, and it has worked perfectly:
tell ...
3
votes
2answers
915 views
Terminal: Path to Network Drive in Applescript
I am trying copy a file up to a network drive in AppleScript.
Normally I would do..
do script "mv ~/Desktop/file.txt ~/Folder/file.txt"
What is the correct path to a network drive? I normally ...
2
votes
2answers
701 views
Is there a way to turn on and off the Mouse Keys feature using AppleScript or a terminal command?
I'm running Mac OS X 10.7.2. Is there a way to run an AppleScript or terminal command that quickly turns on or off the "mouse keys" feature under the Universal Access tab? Ideally I'm looking for a ...
4
votes
1answer
1k views
Script to raise a single window to the front
In a script I'm trying to find the Terminal.app window containing a specific tty device and raise that window to the top. Here's what I have in Applescript so far:
tell application "System Events"
...
2
votes
3answers
591 views
Show text using Large Type without relying on third-party applications
Apple has this amazing feature called 'Large Type', chiefly implemented into Address Book. When you look up a contact, you can right-click the phone number and click 'Large Type', and it will display ...
1
vote
1answer
504 views
List of (activated) fonts with shell command in os x
Is here any shell command for getting the list of activated fonts? Mean something like:
some_font_util -activated -format 'file: name'
for getting a list of activated fonts in a form:
...
2
votes
2answers
946 views
Osascript error
I was messing around with some external libraries, and for some reason when I enter any Osascript command, I now get this error (before it did work):
2011-09-07 19:13:43.306 osascript[1083:707] ...
1
vote
1answer
407 views
Problem setting terminal window bounds with AppleScript
Problem trying to solve
I use multiple terminal windows to develop web applications. I'll have a terminal open for vim, a terminal open for git and a terminal open for basic file/directory commands. ...
2
votes
5answers
3k views
How can I write a script to open multiple terminal tabs and execute code in them?
I want to be able to open the terminal application and have it either automatically run a script that opens several tabs and run an arbitrary set of commands in each. For example I would like one tab ...
2
votes
1answer
562 views
applescript (osascript) for changing Terminal.app profile
Is here a way to changing the Terminal.app profile from the command line?
Here is already couple of questions about changing colors, but I need change the whole profile from the "Basic" (what is my ...
1
vote
3answers
574 views
Trigger 'Gather Windows' programmatically (or other quick way)
I'm trying to make myself a little script that I can run on the fly that gathers all my open windows onto the main display.
I think a good starting place would be to be able to trigger Gather Windows ...
5
votes
1answer
1k views
Is there a way to force Mac OS X to close all the applications when restarting?
I sometimes shut down my Mac, and I cannot wait it shuts down because I am urgently requested to do something in another office that would require some hours. In some cases, an application that opens ...
10
votes
3answers
2k views
How can I “say” to another Mac?
I have two Macs in our house (iMac and MacBook Pro).
I would like to use the say command-line utility to type something on my MPB and have it speak on the iMac, rather like an intercom system.
Plus, ...
2
votes
3answers
639 views
Check if a process is running, if not execute it again in Terminal
Is there a way to periodically check if a process is running with (probably with Apple script, or some other shell script) and if not then to execute it in Terminal?
I have a PHP script that is needs ...
2
votes
1answer
1k views
How to use the built–in VPN Server on Mac OS 10.6.6
I know that Mac OS 10.6.6 has a built in VPN server that one can access through command line. Is there an easier way? Can I make an Automator or AppleScript program that starts and stops the built–in ...
5
votes
3answers
916 views
Automatically quit Terminal when typing exit
Scenario
I use terminal to SSH a lot, however would like the Terminal App to quit when the last Tab closes using exit. I already have the terminal window itself set to close on successful exit, ...