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 (1)

0
votes
1answer
301 views

Whats the equivalent of the unix tree command on OSX

Whats the equivalent of the unix tree command on OSX (10.8.5)
3
votes
2answers
140 views

Is the power button on my iPhone being turned off programmatically?

I would like to know if there is a code / glitch to make the sleep/wake button on the iPhone 5/5S to stop working. i am almost 100% certain it exists due to some programmers making the code but i want ...
2
votes
3answers
1k views

How to manually trigger background image change?

I have set the wallpaper to change every hour and have enabled it to cycle them in a random order. Sometimes the background image changes to an image that was set just few rounds ago and I'd like to ...
2
votes
3answers
2k views

Find/Unrar/Delete Script

I'm a PC convert, and quite novice when it comes to shell/bash scripting, but I really want to learn/understand more. My need: I need to be able to scan a folder, find any .rar files, extract the ...
1
vote
1answer
2k views

How to open a file in Excel from the command line

Is it possible to tell Excel to open a file from the command line? In Linux, I could do this using the command libreoffice --calc test.xlsx
2
votes
1answer
53 views

Cannot seem to download command line tools

I'm trying to download and install Command Line Tools for my Mac through Xcode, but it is not in the downloads section like youtube videos tell me to go. So, I manually download it and install it, and ...
10
votes
4answers
2k views

Updating modifier key mappings through defaults command tool

I am trying to automate the inital setup of my macbook, that includes installing software and changing OS X configuration to my needs. I have tried to update the modifier keys with defaults, the ...
0
votes
0answers
21 views

How do I make the batch command work correctly under under Darwin?

Under Linux, the command batch < script puts the script into a queue, and scripts (jobs) are started whenever the load average drops below a set value, usually 1.5. There's also a delay after any ...
0
votes
1answer
148 views

Add printer via lpadmin with custom queue

Is there a way to add a printer via the command line that has a custom queue that has two words separated by a space? My command so far is below but does not set the custom queue. Without the queue, ...
2
votes
0answers
30 views

Get RSS Memory usage from entire OS on command line

I need to get the entire count of RAM being used on a command line. I can get individual process RSS usage using ps -o rss= -p #{pid} How do I get all the memory usage for the entire system on the ...
3
votes
3answers
136 views

locate & updatedb - files not found

I ran sudo /usr/libexec/locate.updatedb then locate Radium3 but it returns nothing! but $ ls ~/Library/Containers/com.catpigstudios.Radium3/ Container.plist Data So why doesn't locate see ...
0
votes
1answer
161 views

Repeat a song in afplay

I am using afplay to play a song and I want it to be repeat. Is it possible just using afplay?
1
vote
1answer
72 views

skill -KILL -u $user Command on Max OS X?

Is there an alternative for the skill -KILL -u $user command on the Mac OSx. The basic requirement is I want to log out my current logged in user at end of shell script This program logs out Linux ...
2
votes
1answer
271 views

Deleting with rm did not free up space [duplicate]

I deleted a 5gb video using rm video.mp4, but the space hasn't freed. This was the situation: while encoding a video with FCP X, I ran out of space, I only had 50 MB free. Since in the trash I had ...
2
votes
2answers
184 views

make it easier to call often used terminal commands

I have a java tool that I use quite often from the command line but to use it I have to type java -jar dsim.jar. I want to make it so that I can call it just by typing dsim regardless of what ...
0
votes
2answers
364 views

Adding Ricoh C4501 printer via command line - Installable options

I need to deploy one Ricoh MFP to ~50 Mac users. I thus wan't to do this through ARD/CLI. I'm looking for the correct lpoption tags for the Ricoh MP C4501. I want to set the "Finisher" (SR3020) and ...
1
vote
1answer
50 views

Open Ruby installed gems in editor

How to open installed gems in editor such Sublime Text or Text Mate or Atom? I would like to do it from command line like: open -a Sublime\ Text\ 2 something_here
0
votes
2answers
54 views

“newgrp: too many groups” - why is it complaining?

In my earlier question, I got a response recommending the "newgrp" command. It diligently did the job of putting my desired group at the "top of the list" for the "id" command, but, why does it also ...
0
votes
1answer
55 views

Command Line - How do I change the order of a user's group memberships?

I have a troublesome Mac OS X server to deal with. When I ask for my current group membership using this: $ groups | perl -p -e 's/ /\n/g' I get a list of 20+ groups! cactuar ...
16
votes
4answers
5k 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 ...
1
vote
1answer
44 views

Need help to understand how this find command works

I'm a beginner on OS X and I believe this command will make a list of all files and subfolders of specific folders find /Volumes/Documents/ -exec stat -f "%N %Sm" {} + >~/Desktop/test.txt I ...
2
votes
1answer
369 views

How to boot OSX into desktop from single mode?

Is there any possibility to boot graphical mode once I'm in single mode (CMD+S on boot time) logged as root? Related: http://www.mactalk.com.au/11/90219-boot-into-desktop-single-user-mode.html ...
2
votes
1answer
61 views

Equivalent of Ubuntu’s write-mime-multipart?

I would like to generate a multipart mime-encoded document for use as user data on EC2 instances. On Ubuntu, one is supposed to use write-mime-multipart to do this, as per these instructions. Does ...
0
votes
1answer
206 views

Disabling the trackpad from the command line

How can I disable the trackpad (without restarting my computer) from the command-line on OS X Mavericks?
2
votes
0answers
58 views

Does OS X support AnyIP?

I would like to assign a complete block to my mac as described in this question: Can I bind a (large) block of addresses to an interface? There it is explained that AnyIP is supported for IPv6 by the ...
2
votes
1answer
406 views

Escape character ^] not working from Mac terminal

If I ssh into an Ubuntu machine from my Mac with a "UK extended" keyboard and run telnet localhost 4730 I see: me@ip-10-xx-xxx-30:~$ telnet localhost 4730 Trying 127.0.0.1... Connected to localhost. ...
5
votes
2answers
7k views

Why does Java SE 6 Web Start (javaws) not find the JRE with Apple's Java for OS X 2012-006 on Mountain Lion?

In brief The JRE is installed but javaws can not find the JRE. What can I do on the command line to re-enable the web plugin for Apple's Java 6 in Chrome or Safari? I want to avoid Java 7. (We're ...
1
vote
0answers
94 views

What are the command(s) to script a daily time sync?

I'm experiencing clock drift on my Mac Mini of 1-2 minutes every day. Like questioner here, I get relief if I open Date & Time from preferences every day or two. It doesn't stop the drift, just ...
0
votes
0answers
16 views

Top command not outputting all information

I'm trying to put together a script which collects the information produced by the top command relating to the system rather than the processes (i.e. the top few lines). When viewing in top binary ...
17
votes
14answers
8k views

Lock Screen Command One-Liner

I'm trying to find out whether there is any kind of equivalent command line one-liner which replicates the exact identical functionality of the 'Lock Screen' menu option available via the Keychain app ...
0
votes
1answer
42 views

Does MS Word on Apple has any command line interface?

I wonder if MS Word on Apple has any command line interface? I tried the following: $ "/Applications/Microsoft Office 2011/Microsoft Word.app/Contents/MacOS/Microsoft Word" --help but no help.
1
vote
1answer
78 views

Anyone knows how to view the nice value of a process under Mavericks?

Used to be able to view the UNIX nice value of a process in the top CLI utility. I think it's gone from the top utility on Mavericks? Any other ways to view it?
2
votes
2answers
59 views

History commands render incorrect on Bash Vi mode

I'm having this werid and really annoying issue in bash vi-mode. Env: Mac 10.9.2, iTerm 2 1.0 or Terminal.app, $TERM={screen-256color|xterm-256color|xterm|vt} Repro steps: Run some long commands ...
1
vote
0answers
124 views

Building mysql with readline instead of editline

I'd really like to be able to use readline instead of editline with the mysql client, but I can't find out how to do this. The bottled mysql that brew installs by default for mavericks is using ...
1
vote
1answer
208 views

OS X PHP — dyld: Library not loaded: /usr/lib/libpq.5.dylib

What is the problem with my Mac's default PHP? Whenever I do php -version, it shows the following file missing information. How can I fix this problem?
1
vote
2answers
11k views

How Do I Use 'cp' to Overwrite Files?

Using a shell script or Terminal, how do I overwrite files that may or may not be present. I looked at man page for cp, it said use the -f argument to force overwrite. But, it does nothing. $ cp -f ...
2
votes
1answer
493 views

Fixing two user groups with the same ID

Suddenly, my home directory is in the group messagebus instead of the usual staff.(I blame texlive for this, but have no evidence.) The problem is that both groups have the same ID: $ dscl . -read ...
5
votes
1answer
320 views

How to access /dev/mem in OSX?

How I can access /dev/mem (or /dev/kmem, /dev/pmap) equivalent device in OSX? As far as I know it was removed in some point. Can I create this node manually somehow or any other way of dumping the ...
2
votes
2answers
36 views

softlink to Network Location

does anyone know a trick how to generate a Softlink to a Network folder (smb or nfs) the idea is that there are some network folders i use regulary, but they usally not mounted .. the soflink i made ...
19
votes
5answers
7k views

How can I change a file or folder icon using the Terminal

How can I change or set the icon for a file or folder, in the terminal, do I need to use a scripting language?
0
votes
0answers
27 views

How to automate iTunes to iOS File Sharing

Connect an iPad to a Mac via USB and iTunes allows you to copy arbitrary files to apps that support it. How can I automate that? Neither AppleScript nor Automator can do it. Is there a way on the ...
0
votes
2answers
140 views

how to configure Surfraw on OSX?

Has anyone had success configuring Surfraw on OSX? How do I get a working configuration for OSX? http://www.surfraw.org/
0
votes
1answer
2k 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 ...
2
votes
1answer
70 views

How can I move fast in CLI in Mac?

In linux in CLI I can press ALT + F or ALT + B to move back and forth in terms of words and not one character at a time. Is this available in Mac? There is no ALT and I tried Control + F, Fn + F, ...
8
votes
2answers
217 views

Piping multiple commands

I would like to run the following command and pipe stout of both to TextEdit: pmset -g; echo; pmset -g assertions | open -f -a TextEdit This doesn't work, it only executes the latter: How?
7
votes
3answers
4k views

How does Mountain Lion set the default text editor for the “open -t” terminal command?

OSX seem to offer open -t command line shortcut to open arbitrary files in the system default text editor. Where is this default text editor set? Can I change it from the command line (if possible) ...
9
votes
2answers
3k 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 ...
0
votes
0answers
14 views

How do I Install the xcode command line tools without the confirmation and license prompt? [duplicate]

I ended up answering this myself but I figured I'd throw it up here to document it. xcode-select --install asks if you are sure you want to install the script, then it prompts you to accept a license ...
13
votes
2answers
6k views

How can I find the serial number on a mac programmatically from the terminal?

What command can I use to retrieve the system's serial number from the unix command line? As uname will output some information about the software and hardware, I would like to retrieve the serial ...
1
vote
0answers
77 views

Terminal wraps at 80 chars even if window is wider

Problem description If I increase the width of a Terminal version 2.3 (309) window, and then use less (or some command invoking less, like man) in that window, I often get garbled output, since the ...