The default Unix shell used by Terminal in Mac OS X

learn more… | top users | synonyms

0
votes
1answer
27 views

How do I reload an OS X “bash” user-environment

I think that I want to ask How do I reload an OS X bash user-environment But damnit Jim ; I'm a software engineer not a sysadmin The Goal I want Jenkins started as a Daemon on El Capitan I want ...
1
vote
3answers
34 views

Missing bash prompt

My bash prompt is missing as shown on the image. I'm not even sure how to open the .bash_profile since dot files are hidden in the finder. I restarted the machine to no avail.
0
votes
1answer
12 views

How to configure a proxy in a new network location using Terminal.app

I'm writing a bash script, which will create new network location and configure it. The question is - how to add proxy settings to specific network location using terminal or bash script? P.S. I'm ...
0
votes
2answers
57 views

terminal: how do i pipe the results of grep to open a file

I'd like to grep and open a file in just one terminal command. Suppose I'm in this directory: $ ls 1.txt 2.txt 3.txt 4.txt 5.txt and I want to open 3.txt I thought I could do ls | grep 3 ...
0
votes
1answer
29 views

Path not being honored?

I have the following in my .bash_profile: $ cat ~/.bash_profile # Prompt export PS1="\h:\W$ " # Standard path export PATH="/usr/local/bin:/usr/local/sbin:/bin:/sbin:/usr/bin:/usr/sbin: ...
2
votes
2answers
2k views

Bash Terminal keeps showing “No such file or directory” at startup

-bash: /Users/MarksMac/Library/Enthought/Canopy_64bit/User/bin/activate: No such file or directory Basically, how do i remove the above error? I am using a mac 10.9.1 I have tried looking up ...
0
votes
0answers
21 views

Terminal: “Invalid Argument: dirname” (El Capitan)

I noticed the issue when I first went to run defaults write com.apple.finder AppleShowAllFiles YES in OS X Terminal (10.11.2) but this was returned bash: /usr/bin/defaults: Invalid argument I'm ...
4
votes
1answer
2k views

How to enable Maven autocomplete on Mac OS X command-line?

When using Maven (mvn) on OS X Terminal, how can I get tab-completion for Maven goals, plugin names, etc? Things like this: mvn pa [TAB] -> mvn package mvn je [TAB][TAB] -> mvn jetty:run
0
votes
1answer
7 views

How to trigger a bash script from right click in Safari on a particular URL?

is it possible when I'm in Safari and have link (URL) to trigger a bach script with an right mouse option? The bach script should be run with this format: bash scriptname.sh -parameter -parameter ...
1
vote
0answers
19 views

OS X (El Capitan) Terminal Fn-Up and Fn-Down stop working as Page Up and Page Down

I've identified a strange "state" my Terminal program seems to get into. It doesn't happen on all tabs -- right now, one tap can Page Up/Down properly, and another one can't. When I open a new ...
2
votes
2answers
143 views

Cannot kill process shown in parenthesis

I started a rather long dd command that I would like to stop. ps shows: $ ps PID TTY TIME CMD 2006 ttys002 0:00.00 (dd) The dd process is shown in parenthesis without the argument. ...
4
votes
2answers
1k views

-d option for split is illegal on OS X 10.9

I have bash script that works on Ubuntu but for OS X 10.9 i get the error for split command: split -b 1000000 -a 3 -d $F $F && rm $F || { echo "Error: 'split' command not installed" ; exit 1 ...
0
votes
1answer
25 views

sudo and some other system commands not working with platypus

I am making a shell script that works great on its own, but does not work correctly when packaged with Platypus. It does not want to execute sudo, and a few other system commands. Are there any work ...
0
votes
1answer
36 views

How does bash choose default shell

I am running El Capitan 10.11.3 with bash version 3.x so I decided to update bash via: brew install bash Brew places the new bash under /usr/local/Cellar/bash: brew info bash bash: stable 4.3.42 ...
0
votes
0answers
27 views

Uninstall old CMake and its implications

Currently I'm setting up a user account on a Mac Mini that's been used before by others. I found a pretty old version of CMake installed in /usr/local/bin - a pretty default installation path. I ...
0
votes
1answer
21 views

Help running what seems to be a directory in Terminal?

I'm trying to export my Skype chat history with this: https://github.com/Temptin/SkypeExport After I'm in the downloads directory in Terminal, typing in (with my skype username substituted in) ...
1
vote
2answers
3k views

Setting a firmware password

Currently trying to use a script (preferably shell) to setup the firmware password on a fresh OSX install. I obviously found this: http://osxdaily.com/2014/01/06/set-firmware-password-mac/ which ...
0
votes
1answer
28 views

Making Terminal bash auto-complete stop at ambiguous character and display all possible options

The behavior I see happening is that when I type something partially and hit TAB, if there are multiple files/commands that match what I had typed in, only the first one is displayed. Further TAB hits ...
3
votes
1answer
72 views

Why does this cause Mac OSX to print over SSH?

While screwing around and breaking things I came across these stupid commands (if executed in order it causes what I got): cd / && cat vmlinuz cd /boot/ && cat init* It causes ...
0
votes
2answers
16 views

Listing/Moving certain files

My current path is /Users/UserName/Downloads/Downloaded_Path. In Downloaded_Path Folder i have multiple folders like F1, F2 etc and each folder contain rar part-files from rar to r99. What I want to ...
3
votes
2answers
187 views

I deleted .bash_history, now history isn't saved anymore (although I re-created it)

I have freshly installed a new copy of El Capitan. I accidently deleted .bash_history, so I just did a touch .bash_history again, hoping this would solve the problem of my bash history not being ...
3
votes
1answer
60 views

In iTerm, how can I change alt+delete to ignore slashes?

I set up my iTerm to work a lot like OSX does in other text fields, eg ⌘ Command+Delete = delete line backward, ⌥ Option+left arrow = "move cursor back one word" and ⌥ Option+Delete = delete word ...
4
votes
1answer
66 views

update_terminal_cwd demystified please?

I am trying to find the documentation on what, exactly, the printf command is doing in update_terminal_cwd. If you didn't know already, the update_terminal_cwd function is defined (at least on Mac OS ...
0
votes
0answers
17 views

Schedule executing tasks based on bash scripts using CronniX

I'm still quite new you Mac and OS X but do have some background about other UNIX based systems, so please excuse for any misunderstandings. My goal is to implement a function that executes certain ...
0
votes
2answers
55 views

Issue with Automator and bash script

I'm making an automator service, and the first part takes files and RARs them using a bash script So in Automator, I have a Get Specified Finder Items action to test the workflow, and then the bash ...
27
votes
2answers
31k views

List all defined aliases in Terminal

A friend who owned my current Mac before me created a lot of alias commands. Is there a way to list all defined aliases and the command that is associated with them? And if so, am I able to edit ...
0
votes
1answer
24 views

How to get local directory names into terminal window titles?

The title of my terminal window is: Terminal -- bash -- 130x39 This is how I see them listed in Terminal->Window and it is very hard to know which one is which. When I use multiple terminals, the ...
3
votes
3answers
2k views

Compare multi-digit version numbers in bash

Trying to write a script that searches for the version of the Application then returns the value. My problem is the value is three to four intergers long (example 4.3.2). I have searched for a while ...
6
votes
3answers
3k views

Change *.txt to *.csv

How can I rename all *.txt in a directory to *.csv files in the terminal (Mavericks). I tried following inside the directory: mv *.txt *.csv
0
votes
0answers
20 views

Saving space by hard-linking duplicates

I am looking for tool, script etc to hard link (or something equivalent) files with the purpose of saving space. (Going through files, finding duplicates and hard-linking them in). Will also then ...
2
votes
1answer
56 views

Date trash was last emptied bash

I'm trying to find out at what date and time the trash was last emptied. Would it be the date modified of the least recently modified file? Does moving it to the trash count as modifying it?
2
votes
1answer
393 views

How to change the default command to open shells in the MobileTerminal Cydia package

I am using MobileTerminal on iOS 7, and want to know how to change the default shell from sh: to bash:. I assume I would need to change the login command for this, but how would I?
1
vote
1answer
348 views

Auto-updating Homebrew

i'm currently using the Homebrew package manager and my question is: is possibile to write a bash's script in order to execute brew update and eventually brew upgrade whenever opening a shell for the ...
0
votes
0answers
33 views

Is there a command or script in mac OS X to set the creation date to match the modification date?

Somehow, the creation date of all the photos on my USB drive has been updated to a recent date, but the modification date remains untouched. So any photo app thinks the photos were just taken recently ...
2
votes
1answer
63 views

Is it possible to open a Private Browser window in Safari using Terminal.app?

I'm trying to open a Private Browser window in Safari using Terminal. I could open Safari using open command and this way, open /Applications/Safari.app/Contents/MacOS/Safari but I couldn't open a ...
0
votes
3answers
11 views

Retrieving the “Version” attribute of an OSX Application file via Bash

I was initially attempting to do this in Java using the UserDefinedFileAttributeView class but it turns out that is only available on Windows computers (This is being run on OSX) So I switched gears ...
2
votes
2answers
57 views

Why I am unable to switch bash to the one installed by homebrew?

I'm trying to update bash to version 4.x. I did brew upgrade, then brew update, then brew install bash. I ran sudo bash -c "echo /usr/local/bin/bash >> /etc/shells" and sudo bash -c "echo ...
1
vote
0answers
26 views

Getting bash-3.2 everytime I “su”

Whenever I su, PS1 changes to \s-\v\$. Why is that? Tried setting it, but it still changes when I su again, or exit the terminal. What to do?
2
votes
2answers
35 views

Bash history is not remembered in Terminal

My Bash history is remembered when I connect to my Mac via SSH, use iTerm2 or launch bash in the built-in Terminal app (every command I typed in bash is saved) but is not when I just use the built-in ...
0
votes
1answer
57 views

Is $PATH just a file with a list (in order of preference) of directories?

I'm having trouble understanding exactly how $PATH works? I am on a Mac.. If I install Python with Homebrew, it will install Python into the /opt/local/bin directory. Now assuming Homebrew didn't ...
4
votes
1answer
56 views

Duplicating and renaming Finder selection to the same folder in one clean step?

Is such a thing possible? I have this code which can do the above: set now to do shell script "date +%Y-%m-%d' '%H.%M.%S" tell application "Finder" set finderSelList to selection as alias list ...
0
votes
1answer
56 views

OS X El Capitan: man, command not found

Today I was trying to update openssl in my MacBook Pro with El Capitan 10.11.2. I don't know where I made a mistake but it seems I have accidentally disabled man. In fact, if I launch man ...
1
vote
0answers
21 views

Chrome desktop apps (extensions) won't launch at startup on OS X

I'm trying to figure out how to get a chrome desktop app (Kiosk) to launch at startup. I've gone to System Preferences > Accounts > Login items and added Kiosk (User > Applications > Chrome Apps > ...
1
vote
1answer
23 views

Where is my .bashrc file in a dd image?

I created an "emergency" image of my entire HD using the procedure explained in Recover a dead hard drive using dd. I spent a lot of time fine tuning my .bashrc and .profile files, but I cannot find ...
0
votes
1answer
13 views

How can I hook up a PHP server?

I have a php page I want to test on a server. Is there a server that runs through Terminal.app that supports PHP? I read this tutorial, but either I did it wrong or it didn't work. How can I start up ...
0
votes
2answers
57 views

How to Poll USB mouse through terminal in El Capitan

I've been trying to view which devices are connected to my USB ports through terminal in El Capitan, in particular a USB mouse. I've read online that I can ls /dev/tty.* to view all connected devices. ...
3
votes
3answers
58 views

Display interactive notifications (with buttons) via Terminal

I'd like to let my bash shell scripts to display gui notifications with two buttons that the user can click and then execute some commands depending on the button pressed. What options exist?
2
votes
2answers
136 views

Why bash history on my mac won't save?

I have always used bash for work, and never had problems with it. Now, it does not save any command in history again. If I open a window terminal, try some commands, it acts like everything has ...
3
votes
1answer
44 views

xxd not found in Recovery Mode, Mac OS X 10+

In Recovery Mode, I was trying to access my password hashes, except bash 3.2 returned command not found for xxd. Any help would be appreciated.
2
votes
2answers
55 views

DefaultKeyBinding.dict: Can I use it to rebind keys on OS X?

I need a custom keyboard shortcut for back slash \. I have created ~/Library/KeyBindings/DefaultKeyBinding.dict and put this in it: { "@ö" = ("insertText:", "\\"); } It is supposed to trigger ...