Terminal (or Terminal.app) is the program included in Mac OS X for running applications and issuing commands using the command line interface. These programs are controlled by typing lines of text, rather than using the mouse or keyboard commands in the usual graphical user interface (GUI).

learn more… | top users | synonyms

0
votes
2answers
7k views

Mount Shared Drive via AFP in Terminal

I want to mount an external drive, connected on computer A, to computer B. I am able to access and mount the drive by connecting to the server through Finder (Command-K), but how can I do this exact ...
12
votes
2answers
4k views

How can I install the Command Line Tools completely from the command line?

I'd like to script the installation of the the Xcode Command Line Tools. On Mavericks, xcode-select --install will open a dialog prompting the user to install, but I'd like to trigger the install ...
14
votes
5answers
6k views

How can I play a midi file from terminal?

I'm looking for a most simple command line app (or an on-board tool on Mavericks I am not aware of) to play a midi file from the terminal. As plain as possible, something like play myfile.mid. ...
1
vote
2answers
1k views

Symbolic links, why doesn't this work:

me$ ln -s ~/x/y/ ~/Desktop/ ln: /Users/me/Desktop//: File exists Why does this attempt at creating a symbolic link to ~/x/yon the Desktop now work? The only way I can seem to get something like a ...
2
votes
2answers
874 views

OS X's hidden preferences disappeared after Mavericks upgrade?

In past OS X versions, I used some commands to set preferences on my Mac. For example, I used the following command to enable selection of text in Quick Look: defaults write com.apple.finder ...
4
votes
1answer
163 views

Are there any improvements in the Mavericks Terminal app? [duplicate]

Most OS X updates have included a few tweaks to the Terminal app. I know that Mavericks has upgraded a lot of command-line tools, but I haven't seen any reports of changes in Terminal.app itself. Has ...
2
votes
2answers
1k views

Mount .sparseimage from .bash_profile

I need to mount a .sparseimage from .bash_profile but I don't get how to do it. I tried: alias of22='hdiutil attach "Documents/OF.sparseimage" -mountpoint "$HOME/OpenFOAM" > /dev/null ; . ...
4
votes
6answers
2k views

Avg load goes up after upgrading to Mavericks

Just upgraded to OSX 10.9 Mavericks. Everything is good and shiny. However, when I open my iTerm to code, I notice that the performance is lower. If I run a uptime command, the average loading is ...
2
votes
1answer
661 views

Terminal goes slow after install Mavericks OS

After I've update my OS to Mavericks. Terminal goes really slow, I've found out that the problem must be from Xcode. While I remove Xcode from my computer terminal works fine, and after I installed ...
16
votes
5answers
86k views

How do I set environment variables on OS X?

I have always difficulties setting the environment variables on Mac like JAVA_HOME, M2_HOME or PATH. How to set these on Mavericks OS X? I did some research but the answers I've found didn't really ...
0
votes
1answer
495 views

How to socksify apps in mac os

Is there an analog on mac os for http://linux.die.net/man/1/socksify ? So that i can use it like on linux: socksify mongo ....
2
votes
2answers
2k views

manually edit shortcuts on os x 10.9 (Mavericks)

I'm using TotalTerminal on 10.9 Mavericks and while it's not great, it's the best quake terminal I've found right now. I usually show/hide the visor using command-escape but unfortunately can't seem ...
19
votes
4answers
67k views

Why does OS X Mavericks block the purge command in Terminal?

When I try the purge command on my terminal, OS X Mavericks gives me the following message: Unable to purge disk buffers: Operation not permitted This hasn't been the default behavior until now. I ...
2
votes
1answer
481 views

Terminal output as a screensaver?

I want people to keep an eye on a script running in terminal whilst I'm away from my desk, but I don't trust them access to my machine. Is there a way to show the terminal console as a screensaver, ...
0
votes
1answer
146 views

Add a value to CustomPapers' plist using Terminal

I'm trying to add a printer to CustomPapers' .plist using this terminal command: defaults write com.apple.print.custompapers.plist 165x165 -dict-add ...
1
vote
1answer
733 views

terminal starts with `no such file or directory` message

I removed Enthought Canopy from my Mac and now when I start terminal there's this warning message says -bash: /Users/myname/Library/Enthought/Canopy_64bit/User/bin/activate: No such file or ...
1
vote
0answers
398 views

Where does Transmission store logs for called scripts?

Transmission has an option to run a shell script when a file finishes downloading. I'm wondering where to look for logs for it – it seems like it only executes half of my script but can't figure out ...
10
votes
1answer
4k views

How to update some application to latest version with homebrew-cask?

I noticed some packages provided by homebrew-cask uses a url of the latest version and a version number of "latest" such as dropbox and chrome. Thus they will never be upgraded with brew upgrade. Is ...
2
votes
2answers
196 views

Is it possible to remove all installed terminal applications and extensions back to native without doing a clean OSX install?

Basically I would like to know if it is possible to remove all php, apache, homebrew, mac ports etc. installs back to native without doing a clean install of the OS? If not is the best way to go ...
2
votes
2answers
3k views

curl command can't be found, OSX utilities have been replaced by GNU coreutils… how to start from scratch?

I recently installed homebrew and I was having a hard time because I could not install it as curl command couldn't be found, someone pointed me to use wget and that worked to install homebrew but now ...
1
vote
1answer
720 views

mvim (MacVim 7.4) opening new windows rather than tabs (Mac OS X 10.8.5)

I am using the above and editing new files using mvim <filename>. The first time after I installed mvim in the /usr/local/bin directory it seemed to open files in new tabs by default, this ...
2
votes
2answers
2k views

What is the real working method of making a bootable usb drive?

Always when I need to make a bootable usb drive on a mac I struggle, I end up switching to windows because none of the below works for me, I'm using MacBook Pro: running sudo dd if=Debian.is ...
3
votes
1answer
1k views

Mac terminal command: how to 'ls' for some specific files?

My question is about the ls command. If I have too many files in a folder, I might need either: ls files with a given type only or; ls files within a range, i.e., files with names a* to b*.
2
votes
3answers
13k views

Can't change folder permissions

I'm running Mountain Lion and I have a folder in ~/sites that has a red icon on the folder and I can't open it because 'access is denied'. What I've tried: Get Info > unlock with admin password, ...
1
vote
1answer
611 views

Terminal commands for “Application Windows” and “Show Desktop” in Mountain Lion

The title pretty much says it all. I need to know the terminal commands for "Application Windows" and "Show Desktop" in Mountain Lion so I can make aliases on the dock with Automator. I don't like hot ...
2
votes
2answers
4k views

How do I re-enable the Press and Hold character picker on OS X Lion?

I disabled the character picker by reading this other question, but I want to remove that change and restore the picker. When I type -g ApplePressAndHoldEnabled -bool true into Terminal, it does not ...
1
vote
1answer
204 views

no key repeat in Xquartz (x11)

I don't think I've used x11 since switching to Mountain Lion (and thus Xquartz). I recently tried to use it and my key repeat isn't working. When I press a key, it inserts the corresponding ...
1
vote
1answer
53 views

“open -t” vs. “open -ef”

the Command: syslog | tail | open -ef works perfectly on my osx 10.8.5 and opens the required lines from syslog in textEdit, however when I run syslog | tail | open -t which should open the same ...
2
votes
3answers
4k views

How To Securely Erase Free Space Using Terminal?

A friend told me that when you delete a file on your Mac in the normal way it actually stays where it is, but it is just no longer usable by your Mac. The addition of more files to your Mac causes ...
1
vote
1answer
154 views

Can I map a character to a different key?

I am using a British IBM model M keyboard with Mountain Lion. I have selected the "British - PC" input source and it is working well, except for one key: the pipe. If you consider what is printed on ...
7
votes
2answers
473 views

How can I process/read checkmarks on a paper form?

I would like to process a large number of scanned paper forms (GUI or command line). I am only interested in reading (custom) checkboxes. The form looks like this: every line has 6 circle-shaped ...
0
votes
1answer
95 views

Error Opening Image File in Terminal

Much like: How do I cat a deleted file which is still open by its inode?. I am using 'Sleuth Kit' command line tool, to gather relevant data from the disk. But I keep on getting: Error opening image ...
2
votes
1answer
202 views

Search files across folders and move recursively to new folder

I need a way to search from a base folder, all the folders inside of that one recursively, and find all photos of JPG and PNG that were created before a certain date (01.Feb.2013) and then move them ...
6
votes
3answers
428 views

Terminal command to bring up shutdown dialog?

I know how to shutdown a Mac from Terminal, but is there a way to actually bring up the shutdown dialog you get from Apple → Shut Down…?
1
vote
3answers
6k views

How can I create custom right click context menu items in Mountain Lion? (“New File”, “Open Terminal Here”, etc.)?

I've been a native windows'er up until this year and have finally made the jump to OSX. I've found my workflow (web developer) has increased substantially and I love the general performance and ...
3
votes
1answer
2k views

How to fix multiple errors when installing Homebrew on OSX Lion (mainly OSXFUSE and Mono related)

I'm trying to install Homebrew but I'm getting multiple errors when brew doctor is run. I'm a complete noob at this and I've tried uninstalling Homebrew and re-installing, but still not working. ...
6
votes
3answers
4k views

Disable Spotlight Index on 10.8 on Specific Volumes

To switch off indexing in Terminal I use: sudo mdutil -a -i off This disables it with the -a switch across all volumes and the -i off part turns "off" the indexing. If connected to my iMac is the ...
14
votes
3answers
14k views

Run AppleScript from bash script

If I wanted to run an AppleScript from within a bash script I could call a file with the list of commands that I require to execute. #!/bin/bash {some commands} osascript file.scpt {other commands} ...
3
votes
1answer
112 views

Exporting the filepath of all music files to a text file

I'd love to know the syntax within Terminal to export the filename and path of all my music of various types (I have legacy Windows .wma files too). I'd presumably export those file to a .txt or .xls ...
6
votes
2answers
4k views

What does -HUP do when used with killall?

Sometimes when I'm running a killall command from Terminal, a co-worker would suggest or edit my scripts to show killall -HUP. What does the -HUP part do?
4
votes
2answers
550 views

Pipe output of grep to a variable

I need to be able to write whether the test for a grep is either TRUE or FALSE to a variable so I can use it later For the following, if I run defaults read com.apple.Finder | grep ...
1
vote
1answer
166 views

Using The Terminal Command and Emacs To Play The Video Game “Tetris”?

OS X via the Terminal command and Emacs apparently allows you to access and play a version of the video game Tetris. How do you accomplish this (and can you play via keyboard controls) ?
4
votes
2answers
3k views

Changing The Dock's Appearance From 3D to 2D?

Sometimes the glossy finish to the Dock 3D's appearance annoys me, and I want something less bedazzling on the eyes. Is there a simple terminal command I can use to convert it from a 3D glossy to a ...
18
votes
2answers
84k views

Using The Terminal Command to Shutdown, Restart and Sleep My Mac?

I'm getting more interested in using Terminal as an alternative way to address solutions on my Mac. I have seen this question entitled "Is there a better way to shutdown/restart OSX?". I would ...
4
votes
2answers
1k views

Bash Script that will start up second Terminal process?

I need a script that will be able to fire up a second Terminal instance and pass a command directly to that one whilst it continues it's own executions. It's to start up Python script that will host ...
0
votes
1answer
170 views

Finder hiding specific file by name

At some time my MBA 10.8 Finder decided (or was it me) to hide certain files from me. Here is the example (I have few other files like it) .. The Water Horse.flv Originally those files are ...
0
votes
0answers
88 views

Bash Commands and Terminal problems [duplicate]

Hello I open my terminal window on Mac Os 10.6.8 as I am trying to update my ruby to 1.9.3 and the terminal gives me this response immediately as I open it: -bash: export: ...
12
votes
3answers
5k views

Show package contents from command line

When working at the terminal, I often use the open . command to open a finder window showing the current working directory. But if the current directory is actually a package, like a .app application ...
2
votes
1answer
421 views

Homebrew: Easy way to add 'gnubin' to path for multiple packages?

I would like to use Homebrew to install GNU versions of several utilities, and use the GNU versions by default with their usual names. From the output of brew install gnu-tar and by reading How to ...
3
votes
2answers
54 views

Man md5 displays dgst man page

I just wanted to look at the man page for the command md5. So I typed man md5 but it displayed the man page of dgst instead of this one. Any idea why and how I could access this manpage from the ...