questions narrowly about terminal.app alone should use this tag. Please consider using **command-line** for any question not specifically about the native terminal app

learn more… | top users | synonyms

0
votes
1answer
18 views

Reverse SSH tunnel daemon

I own a Macintosh laptop (10.11.2) that I would like to create a permanent reverse SSH tunnel. This way, when I switch network, or the computer is stolen, I can remotely SSH into the device ...
0
votes
0answers
48 views

How to Have Stereo Macro in OS X Vim?

OS X Terminal Emulator with Custom Escape Sequences I am not sure if OS X terminal emulator is sufficient for the escape sequences. Current cursor on line of path in Vim etc ./InfectiousDiseases/1....
2
votes
2answers
3k views

Open a new Safari window in the current Space from Terminal with multiple tabs (URLs)

How to open an new Safari window from Terminal in the current Space? Now when using the open http://example.com command it opened the URL as last tab on my first Safari window. I'm looking for a way ...
1
vote
2answers
471 views

CCID installation El Capitan

I am trying to install ccid-1.4.20 (command line) in an El Capitan enabled MacBook Air, but I am facing some issues. Instructions says that after uncompressing the file, in the generated folder I ...
0
votes
1answer
39 views

Can the cp command be used to restore a hard drive?

My cousin contacted me for tech support because her computer was refusing to boot to the startup drive, and the issue turned out to be a corrupted drive that Disk Utility refused to fix, telling us to ...
0
votes
1answer
43 views

change screen resolution with AppleScript

How can I change change screen resolution using AppleScript? If AppleScript can't do it, what about Terminal? I tried with examples at How to set screen resolution with a keyboard shortcut on Retina ...
5
votes
3answers
19k views

How do I force a partition and format on a USB key in OS X Mountain Lion Disk Utility or from CLI diskutil?

I have a brand new Memorex TravelDrive 64GB USB disk which is being troublesome. It's formatted FAT16 on MBR, which is not so nice, and I'd like to put it on HFS+. I've tried to do this through ...
1
vote
1answer
312 views

Symbolic link to Emacs 24 not working

I like to create a bin directory in my home directory and make it the first item in my $PATH. I then create symbolic links to override the default MacOS installed version of certain apps. I have done ...
3
votes
1answer
164 views

OS X : Terminal command to turn ON/OFF SSH server

I know how to turn on SSH server from System preferences :- (System preferences -> Sharing -> Remote Login ) Now I am looking for a terminal command for the same. By knowing it I can use the ...
5
votes
5answers
3k views

Copy to clipboard from Tmux in El Capitan

I am quite happy with the Terminal changes in El Capitan (see e.g. this question). However, i can't figure out how to enable copying to system clipboard from within Tmux. For instance, now that I am ...
3
votes
3answers
33 views

Why does the Terminal app icon show an unread message?

For the first time in roughly three years, the Terminal app icon in the dock shows that red new message overlay. To the right, the same happens with Thunderbird which I am used to as I do have ...
0
votes
1answer
63 views

How to change timezone in recovery mode? [duplicate]

I have a MacBook pro and I'm trying to instal OS X El Capitan on a clean formatted SSD hard drive. While installing I encounter an error saying "this copy of the instal os x el capitan application can'...
3
votes
1answer
63 views

Add command to sudo in OS X - or how to fix a major security inconsistency in OS X

OS X provides Keychain Access, which is a great way to save passwords of varying apps and websites. When you want to view a password via the Keychain Access GUI, you are asked the admin password. ...
1
vote
0answers
32 views

SSH keybased authentication using smartcard

I originally posted this on Information Security but am hoping to attract an answer here since this is OSX specific. So I'm fairly new to more secure forms of key management, I've been used to ...
1
vote
1answer
42 views

The terminal on my Mac does not work anymore after installing Python & Sublime Text

I was trying to install Python3, and Sublime Text 3 in order to learn and run Python. Unfortunately, I watched some videos on youtube and tried to follow their instructions, I did something with my ...
0
votes
0answers
49 views

Get result of Terminal tab do script via commandline

I've seen similar questions like this but none seem to deal with getting the result from a specific Terminal tab? I'm writing a Chrome extension to do some awesome stuff. Right now I'm just trying to ...
0
votes
2answers
52 views

prevent networksetup from asking for password

I am trying to get rid of password when changing proxy with networksetup. I changed permissions to read and write of /private/etc folder and propagated change to subfolders. I tried this: sudo chmod ...
0
votes
0answers
28 views

Use Terminal to echo a Messages chat

What script/command could I use to echo a readable format of my messages with someone? Is there any way to echo the chat.db as a table for that one person who I am chatting with?
7
votes
2answers
15k views

How to move the Downloads folder (in Mountain Lion) to another disc

I want the "Downloads" folder not on the system drive but on my second internal drive. In Lion I just deleted the "Downloads" folder and replace it with an alias with the same name (pointing to the ...
1
vote
1answer
89 views

Automator: “Run Shell Script” throws error because of missing “on” command

OSX 10.11.4 here. I'm trying to create a workflow for use with a hotkey, to run a simple shell script. Created via: Automator -> New Service -> Utilities -> Run Shell Script, then set to 'no input' ...
13
votes
5answers
67k views

“-bash: ls: command not found”

I installed the most recent update to OS X Lion (10.7). After I did that, my terminal won't recognize normal commands. I typed ls and got: -bash: ls: command not found I figured I'd try to add usr/...
1
vote
4answers
12k views

How to access the Wi-Fi password through Terminal?

I am at my school and the computer I am currently using is connected to a Wi-Fi network. I want to know the Wi-Fi password and I am on a Mac. I know there is a way to do it through Terminal. What I ...
1
vote
4answers
80 views

In Terminal, how can you determine which shell is actually running?

Using Terminal on OS X 10.11.4, initializing Terminal opens a new window running bash (by default). As I understand it, inputting echo $SHELL should output the shell that said command is submitted to. ...
1
vote
2answers
2k views

Install Monokai Theme on Terminal with prompt colors, etc.?

I already have a Monokai theme installed in Terminal, as so: I was wondering how I could get the rest of the Monokai (as Sublime uses) into Terminal? Like, making the prompt (Gamma@~) colored, etc. ...
1
vote
1answer
70 views

How to avoid password prompt in terminal?

So sometimes my Mac loses its connection to the Internet. When I'm in front of it physically I can use the terminal and do the following to repair it: networksetup -setnetworkserviceenabled ...
2
votes
5answers
2k views

How to produce constant output in a Terminal window?

Like when you do brew install wget or mysqld restart I want some lines of information constantly run through my terminal window. Is there maybe something I can monitor or any stream of information I ...
0
votes
1answer
34 views

update git repository with apple script

I want to update my git Bitbucket online storage with apple script. This is the code that works in Terminal, but not when i run apple script. cd /Users/mainuser/Desktop/Projects git add -A git commit ...
2
votes
3answers
5k views

Alfred: How to get Alfred to run a terminal command?

I often need to run multiple copies of an app, like VLC. For this I use the terminal and run a command similar to: open -n /Applications/VLC.app How can I create a shortcut with Alfred to run this ...
0
votes
1answer
28 views

How to add shortcut to directories to OS X menubar

I have several directories that I want to quickly access in Terminal. And sometimes even in the finder. I would like to be able to hit an icon in the menu bar and have it drop-down a list of folders ...
1
vote
2answers
146 views

Backup files from Terminal in Recovery Mode

I want to transfer files in Recovery Mode https://support.apple.com/en-us/HT201314. I opened Terminal in Recovery Mode and tried to copy files to external hard drive. I use this code // I used cd .. ...
1
vote
1answer
61 views

No Macintosh HD in Volumes folder

I am running in recovery mode to save the data from disk( I cant login due to deletion of private/var folder). I opened Terminal and went to Volumes. This folder should be populated with the Macintosh ...
1
vote
1answer
403 views

Full screen always enabled when opening app in OS X

How can I set my Macbook Air to always open new apps in full screen mode? Some apps already do it (Mail for example), but others are always opening as a small window, especially Safari when I close (...
1
vote
0answers
17 views

How to disable LoginWindow (boot to Darwin console)?

This may seem like an odd question, but it's one I've been wondering for quite a while. There is an old trick to get access to a console by typing >console as the username in the login window. ...
10
votes
1answer
2k views

How to share history between terminal tabs?

I generally find myself using two or three tabs in my Terminal on OS X. A minor inconvenience is often that the tabs don't share a command history. So things like history | grep thingIamlooking for ...
3
votes
2answers
301 views

Terminal App: What comes after connection?

I want to use an SSH connection to upload large photo files to a server. FTP taking 10 minutes per photo. Someone suggested SSH; I have managed to get the computer connected to the server, but I don'...
7
votes
2answers
468 views

How do I swap Ctrl and Alt in just the Terminal?

I have a USB keyboard where I swapped my Cmd and Ctrl keys, because I come from the world of Linux and that's just what I'm used to. However, this causes a problem in the Terminal because all of a ...
108
votes
9answers
81k views

What is the difference between iTerm2 and Terminal?

I keep hearing that iTerm2 is much better than Terminal. I downloaded iTerm2 today and played around with it, but I couldn't see what is so much better about iTerm2. iTerm2 seemed just like Terminal. ...
2
votes
1answer
289 views

How to change the “Recovery HD” partition to type “Apple_Boot”?

Typing in the terminal diskutil list gives me this... /dev/disk0 (internal, physical): #: TYPE NAME SIZE IDENTIFIER 0: GUID_partition_scheme ...
0
votes
1answer
27 views

Disable automatic “remind me on a day” in Reminders?

I use Reminders simply as a set of todo lists. Today I created a reminder to "buy a shirt, size 14-1/2 32/33", and Reminders added a due date of "2016-01-14 12:00" (not sure how it calculated that ...
0
votes
0answers
56 views

My Mac is slow after upgrading the OS

Recently, after upgrading to EL Captain, my terminal has slowed down way too much. Should I go back to my previous OS? My Mac has 4GB RAM and a 500GB HDD. Macbook Pro 13-inch. It has been one and ...
1
vote
2answers
58 views

How to clone a damaged HD?

Been through a bit of the suggested answers, nothing has been suggested that I haven't tried (unsuccesfully, as of yet), so I turn to the group for answers. I have a 2.5" HD from an MacBook 2011-...
0
votes
0answers
29 views

saving / restoring the NVRAM

I need to find a reliable way to save and restore the contents of NVRAM Would it be correct: Preservation nvram -x -p > ~/nvram.xml Recovery: sudo nvram -x -f ~/nvram.xml Thanks in advance ...
1
vote
1answer
37 views

Set Computer to Sleep Mode for Specific Amount of Time from CLI

This terminal command sets the computer to sleep mode: osascript -e 'tell application "Finder" to sleep' How can I make the computer sleep for a specific amount of time, say 20 minutes? Do I need ...
0
votes
1answer
24 views

How do I remove a ColorSync profile from a JPEG image from Terminal in El Capitan?

I have several images that I would like to strip the ColorSync profile from. Eventually, I would like to automate this in bash so I could easily process this on a file or folder from the contextual ...
-1
votes
1answer
20 views

Backing up data

I have a script that used to run daily that looked like the following to backup my mac. Backup script pastebin As you see here, this script is TERRIBLE because it deletes everything in the folder ...
27
votes
5answers
17k views

Can I disable Dashboard in Mountain Lion?

I'm wondering if there's a way to disable the dashboard in Mountain Lion. I never use it and I think it's consuming processor and memory powers.
5
votes
1answer
790 views

How to make Font size equal to 15 in Terminal on Mac OS X Yosemite?

Here are the configuration settings for the Terminal app in Yosemite. It shows that I can set font size to the distinct values given in Terminal. How can I set it to some other in-between value ...
4
votes
4answers
7k views

How to open a new Terminal tab in current working directory?

I want to create and run a bash function that: cd into a project's directory Open a new tab in Terminal in the same directory Open my dev tools and start dev services Item #2 doesn't work as ...
1
vote
1answer
867 views

Which mail daemon does OS X 10.8.4 run by default?

I'm debugging some mail related stuff on my Mac, and not quite sure how my system is even sending mail. I can run a simple command like date | mail -s test myemail@mydomain.com and receive an email ...
0
votes
1answer
28 views

How to execute app DVD through Terminal of recovery flash drive?

I have a Mac OS X 10.7 Lion recovery usb flash drive. It still boots but won't install Lion anymore (an error occurred during installation). I don't have a install DVD, however the MacBookPro's were ...