Using programs and commands that do not have a graphical user interface (GUI) but are rather controlled by typing text commands into a terminal program, or shell.

learn more… | top users | synonyms (2)

0
votes
1answer
10 views

Exception in thread “main” java.lang.UnsupportedClassVersionError (Trying run Alda on OS X)

I've hit a wall with trying to get Alda to run on OS X. It's an executable I downloaded from here; then, as per the installation guide on GitHub, I ran chmod +x alda on it, and then moved it to my /...
7
votes
1answer
5k views

Missing .bash_profile and .bashrc files

I don't have .bash_profile or .bashrc files and I am definitely using the bash shell. I am using Mac OS X 10.11.1 El Capitan. How do I permanently modify my $PATH to cut down the default values Apple ...
0
votes
1answer
944 views

Is it possible to switch from Safe Mode to Normal and back without a reboot?

Since 10.6.3, Apple has decided change the AppleIntelCPUManagement kexts, which leave me stuck with a kernel_task that pegs out at 135-185%, generating a lot of heat. Anyway, since I doubt anyone has ...
4
votes
1answer
211 views
+50

Removing XCode while keeping the command line tools (on El Capitan)

As by subject. There are a number of links, such as this that deal with the issue but are not El Capitan specific and/or are just not that on the subject or are not up to date. Is it possible to ...
54
votes
9answers
17k views

How do I speed up new Terminal tab loading time?

How can i speed up the terminal startup in Lion? I'm not referring to the startup of the Terminal application, but to the startup terminal windows, like when i open a new tab. I don't have anything ...
3
votes
2answers
443 views

Where is “mkpasswd” for OSX?

There is a well-known unix utility called mkpasswd available on many *nix systems. I was just trying to use it from terminal on an OSX 10.10.5 Yosemite (Early 2015) machine, and it is nowhere to be ...
138
votes
6answers
69k views

git auto-complete for *branches* at the command line?

On my linux machine I have autocomplete for branches with git. [Note we are talking about git branch completion, not bash completion (e.g. commands, files, etc). Thus NOT lane's answer at all] For ...
17
votes
2answers
2k views

Why is lsof on OS X so ridiculously slow?

I can't figure out why lsof on my Mac (10.8.2, MacBook Pro) is so slow. On my Mac, lsof takes more than a minute: $ touch /tmp/testfile $ time lsof /tmp/testfile real 1m16.483s user 0m0.029s ...
0
votes
1answer
107 views

Last command source file

Despite what I thought, there does not seem to be any concrete/modern answer on the net, so my question is: where does the last command get its information from? I have found the file before, but ...
1
vote
2answers
64 views

Finding files with square brackets in filename

I have a ton of files - TOSEC ROM sets - on my Mac (El Capitan) that have filenames suffixed with a tag in square brackets - for example Manic Miner (1983)(Bug-Byte Software)[a] Manic Miner (1983)(...
3
votes
3answers
1k views

How can I determine if the screen is asleep in Mountain Lion, from the command line?

I have a script that needs to run every so often, but only if the screensaver is active or if the screen is asleep (to make sure nobody is actively using the computer first). I need to have a way to ...
0
votes
1answer
30 views

Terminal.app and tmux session, can't use “open” command (without tmux it works)

I use Terminal.app and a tmux session. > open -a VLC file.mp4 The window server could not be contacted. open must be run with a user logged in at the console, either as that user or as root. ...
2
votes
2answers
8k views

How can I make an Automator service run a shell script and display the output?

I'm using Automator to run a shell script (ffmpeg transcode to h264) as a 'Service', so that I can just right click the high res .mov file and select the service. It works fine, but as it's ffmpeg it ...
2
votes
4answers
47k views

How to send text with telnet in Terminal?

I would like to send some text to a port on my machine using telnet in the Mac OS X Terminal. I start telnet using: telnet localhost 8080 Then I type some text. Is that text send automatically or ...
0
votes
1answer
26 views

Command-line keychain access not showing any results [duplicate]

I have been trying to learn to control my computer through command-line, and keychain access is what I am trying now. I have been using the security command, and attempting to get my wifi password (I ...
0
votes
1answer
34 views

Problem “do shell script” on curl – Works in Terminal, but not via “do shell script”

I want to use "curl" with "do shell script" in an apple script. It already worked some months ago, but then the provider changed to https-only service. So I update curl on Mac OS Terminal: $ curl -V ...
2
votes
3answers
1k views

How to remove space character (whitespace) from end of filenames and foldernames?

Problem with mac is that it allows space character at end of file or folder. If this file or folder with space character in end is beeing copied to FTP using Filezilla or Dropbox then mac makes ...
0
votes
1answer
35 views

How to encrypt zip file and filenames via command line?

Using command line on Mac, I know that I can encrypt a directory with the following command: zip -er Directory.zip /path/to/directory However, this does not encrypt the filenames themselves. If ...
0
votes
0answers
8 views

How Deep Do I Need To Define Paths for the Cosign Terminal Command?

My company is registered as an Apple Developer. Our firm has created Mac apps outside of Xcode that we want to code sign. They will run on OS X 10.8+. This link shows the tasks needed to code sign ...
0
votes
1answer
38 views

How to remove __MACOSX folder in a list of zip files (not a single zip file)?

I know I can remove __MACOSX in a zip file by: sudo zip -d bg1.zip "__MACOSX*" but I want to remove it in all zip files, I tried sudo zip -d *.zip "__MACOSX*" but it says zip warning: name not ...
33
votes
6answers
122k views

How do I start TextEditor from the command line?

I work a lot at the command line in a Terminal and would like to start a text editor on a certain file. I'm from Linux Land and normally use kwrite or gedit from a bash shell. Trying to find the Mac ...
10
votes
5answers
10k views

PageUp and PageDown keys for Irssi (IRC) in Macbook?

I cannot find the keys on my mackbook. I need them to go page-up and page-down in irssi (IRC). I have tested the tips here but they do not work. They model some different Up/Down, not the traditional ...
0
votes
0answers
9 views

duplicate image: find the same image in different resolutions (low, middle and hq)

There are lots of Open Source (brew) and App Store software about duplicate image finder. Mostly they do things like a checksum on files. I have a different use case. I have the same image in lot of ...
5
votes
2answers
6k views

How do I install handbrake cli?

I've downloaded the Handbrake CLI. What's the best place to install a command line app on my Mac?
7
votes
3answers
808 views

Moving .bash_profile to Dropbox

I'd like to move my .bash_profile to Dropbox to have my custom Terminal functions available on all my Macs. Is this possible and are there possible implications? For example I have a command for ...
6
votes
3answers
10k views

Is there any way to access the console logs on an iOS 8 device without installing Xcode?

The title says it all. Prior to iOS 8, one could use iPhone Configuration Utility, but that no longer works. Is there any other way to access these logs without installing the gargantuan XCode? Are ...
1
vote
1answer
36 views

output of the who command

I am trying to understand the output of the who command. When I add the -H flag to print the headers, the second column ( the one signifying the users logged in) is titled LINE. I am trying to ...
-1
votes
0answers
17 views

How can I change the language to english from japanese of applications ran in terminal?

the language of the applications ran in shell (like Wine or ssh and sshfs) changed language to japanese (see image below) but when i use the terminal normally it's in english, does anyone knows what ...
0
votes
1answer
36 views

Does the `mdls` terminal command access metadata in resource forks?

I always knew that Mac operating systems had a concept of "resource forks" but have just learned that this feature has in fact been deprecated since the arrival of OS X. I also just discovered the ...
3
votes
1answer
38 views

what is the style of command line editing used by the terminal emulator?

in bash in gnome terminal in Ubuntu, the command line editing commands are by default emacs-style, and can be changed to vim-style. In bash in the terminal emulator of Mac, the emacs-style commands ...
2
votes
0answers
37 views

How can I install bind-utils on El Capitan

I would like to use DNSSEC tools (like dnssec-keygen, dnssec-signzone, ...) on my Mac without running or installing the BIND9 service. Unfortunately for me Homebrew seems only to have the BIND9 ...
1
vote
0answers
27 views

Bash Ctrl-A Returns to Start of Line but Doesn't Display Properly

When I ssh into a Linux server from bash Terminal, I can use CTRL+A to return to the start of line properly, and CTRL+E to go to end of line and everything works fine. When I use bash locally on my ...
4
votes
2answers
2k views

Using the -Bless Command on Multiboot Macs with 10.11 El Capitan

As part of our standard deployment, we tend to deploy multiple OSs on Macs, from 10.7 to 10.11. However, with the new SIP (System Integrity Protection), the -bless command no longer works properly. I ...
0
votes
2answers
95 views

Find readable with Permissions as POSIX?

Aimed systems: Linux and OS X. Original code which works in Ubuntu 16.04 but not OS X, but follows unsuccessfully POSIX standards gfind ~ ! -readable -prune -o -type f -name "*.tex" where ! is ...
5
votes
2answers
325 views

Installing fonts from terminal instead of Font Book?

I know how do install new fonts using Font Book. Is there also a way to install fonts from the terminal, using some smart shell command?
0
votes
1answer
15 views

How can I tell if a particular directory is connected to a remote machine?

I've found various ways to check if a particular directory is mounted under NFS (here, for example), but none of them seem to work on OS X. How can I check if a particular directory is an NFS ...
8
votes
1answer
97 views

checking path capitalization of pwd

Is there a quick way to check in terminal that the terminal command pwd returns the correct capitalization of the path? Note that if you do cd ~/desktop then pwd would tell you that your path is /...
3
votes
3answers
156 views

Find executables associated with Homebrew Formula

Some Homebrew formulas have names that do not correspond with any of the installed commands (e.g., coreutils, speech-tools), other formulas provide an command that matches up with the name, but also ...
4
votes
2answers
11k views

May I have a list of “System” group names, and their respective gid(s)?

I know there are group names such as "Staff" and "Admin", but are those the only ones? I suspect that the root user should also be assigned in a group. Using the command dscacheutil -q user tells me ...
0
votes
1answer
213 views

lshw or lspci for Mac OS X

What's the closest alternative to something like lshw or lspci on Mac OS X? The closest thing I know of is system_profiler but it spits out way too much unnecessary information.
11
votes
2answers
3k views

Shell Script for Yesterday's Date

I'm trying to execute the following shellscript with hazel app on any file in the folder. It works, but the only thing thats causing a problem is the date for yesterday. #! /bin/bash saveDir="TJ" ...
102
votes
5answers
188k views

Can I open files in TextEdit from the Terminal in Mac OS X?

I frequently find that a terminal command to open a file in TextEdit would be very handy. Does such a command exist on Mac OS X?
0
votes
0answers
10 views

How can I put a Realtek wifi adapter in monitor mode?

I have an ALFA awus036nhr wifi adapter and can use it in monitor mode in Linux but I can't use airmon-ng in OS X even though I have airocrack-ng installed, and running tcpdump -Ii en6 returns: ...
0
votes
1answer
33 views

What automatic script runs with Bourne Shell (/bin/sh) for root?

I want to add some aliases to my OSX command line environment for easier navigation when in the root prompt (sudo su to root). On the Bourne Again Shell (/bin/bash), I can edit /var/root/.bash_profile....
2
votes
2answers
2k views

Change accessibility setting on Mac using terminal

I would like to grant accessibility permission to some apps on Mac using Terminal as per this intruction https://support.apple.com/en-au/HT202866 which is the accessibility tab in System Preferences ...
42
votes
3answers
20k views

Linux' `ps f` (tree view) equivalent on OSX?

How can I get a tree view like the one below on OSX? vartec@some_server:~$ ps xf PID TTY STAT TIME COMMAND 11519 ? S 0:00 sshd: vartec@pts/0 11520 pts/0 Ss 0:00 \_ -bash ...
4
votes
1answer
121 views

How to access GPS data from command line on jailbroken iPhone

Are there any binaries available via the command line to get information from the GPS on a jail broken iPhone? I've searched through Cydia and haven't found anything, but I wouldn't imagine this ...
0
votes
0answers
22 views

Can't delete keychain items with UI, but command line works fine

When using the Keychain Access app, I am often unable to delete an Web form password item. I have tried hitting the delete key and going to Edit > Delete. In both cases, nothing happens, there is no ...
-1
votes
1answer
59 views

Can naming/running a program “sudo” somehow cause problems?

I hope this is an appropriate place to post this--I have no idea what happened. I named a c++ file (a simple sudoku solver) "sudo.cpp" and then compiled it with "g++ sudo.cpp -o sudo" and ran "./sudo"...