The default Unix shell used by Terminal in Mac OS X

learn more… | top users | synonyms

2
votes
1answer
28 views

How can I run a shell script that prompts for user input from within Applescript

I have two pieces of code. One is Applescript and the other a Bash shell script. The shell script needs to run concurrently with the applescript, return some values and then exit. The problem is the ...
2
votes
1answer
32 views

El Capitan get current desktop name from bash

I am trying to write a bash script that needs some identifier of the current active desktop (I want my emacs-clients to connect to different servers depending on the active desktop). I have searched ...
0
votes
1answer
52 views

I lost my bash commands (error command not found) [on hold]

I was trying to set up Python environment (virtualenv and virtualenvwrapper, following this tutorial - Install OpenCV 3.0 and Python 3.4+ on OSX) and that's where my problems started. The wrapper was ...
2
votes
1answer
17 views

How to export Moom settings (especially keyboard shortcuts) to external file?

I'm working on some shell scripts to customize OS X to my preferences just by calling one script. From a lot of native OS X options, script is going to easily import some predefined settings form 3rd ...
0
votes
1answer
27 views

Help Understanding Terminal's Command

OS X 10.11.5 on a Mid 2011 iMac. I'm new to development on OS X and am trying to understand enough to figure out a Ruby path issue I'm having. I ran Inspector on Terminal and was surprised by the ...
0
votes
1answer
46 views

Creating a Installpackage for mac

I have a lot of Programms that i always need to install to a new mac. I wanted to simplify this process through an installpackage. I allready tried Iceberg with some success but have a specific error. ...
0
votes
1answer
44 views

How can I edit the .bash_profile?

I want to use matplotlib in Python, but it gives me this error "ValueError: unknown locale: UTF-8". So I searched the internet and people suggest that I should edit my .bash_profile. But when I open ...
0
votes
1answer
26 views

OS X Automator: Using custom command in AppleScript's “do shell script”

I have recently asked a question about automatically inserting a value produced by a custom executable into a prompt field. Please look over this post to know exactly what I am talking about. The ...
2
votes
3answers
134 views

Set the result of command to variable in Terminal post execution

How can you set the output of a command run in terminal to a variable after it has run? Background (You can skip of you don't need the background) I run VirtualBox VM and do a lot from the command ...
1
vote
2answers
36 views

Why does 'set -x' cause the terminal to dump garbage

This problem is quite annoying and I cannot search Google for 'set -x' because the minus sign has another terminology there. In my MacBookPro, when I use 'set -x' to debug bash commands, I'm getting ...
1
vote
0answers
32 views

Are there any advantages to using GNU over the default OSX command line utilities? [closed]

Are there any advantages to using GNU utilities (installed via homebrew) as opposed to the default, BSD based OSX utilities? They seem very similar to me, but I will not pretend to be a master of ...
2
votes
0answers
24 views

Set up a Mac to run OSX (None Browser) application in pure kiosk mode

I've been trying for a number of months, using many methods, to run a Nuiteq Application called Snowflake on our 10 Mac Minis attached to touch-screens in pure Kiosk mode. I'm using Yosemite. These ...
0
votes
1answer
24 views

I get a bash syntax error message every time I open Terminal on macbook

-bash: /Users/admin/.bash_sessions/720116FC-4C25-4FFA-AC15-00D5C843C15F.session: line 1: syntax error near unexpected token (' -bash: ...
3
votes
1answer
140 views

Why does OS X have bash v3.2.57?

OS X comes with bash version 3.2.57 instead of bash version 4.3.39, which GNU lists as the current stable release of bash. Is there any way to upgrade bash on Mac OS X?
-1
votes
0answers
24 views

System Integrity Protection removes (DY)LD_* environment variables: How do I get around this?

System Integrity Protection strips some environment variables, such as LD_LIBRARY_PATH when calling protected binaries. If you use a (ba)sh script or the env binary to pass a script on to some ...
0
votes
1answer
63 views

Extract text between two unicode symbols using AppleScript or bash?

My goal is to take text from a standard .txt document, and use (preferably) Terminal or Applescript to extract text between the symbols ▶ and •. While there is only one ▶ symbol there are multiple ...
1
vote
1answer
24 views

Change iTerm2 profile depending on current directory

Using my .bash_profile, I used to change my iTerm2 profile per machine with the following command: echo -e "\033]50;SetProfile=ssh\a" Now, I want to change it depending on my current working ...
12
votes
4answers
193 views

in terminal, I cannot type lower case e

2015 MBP, fully up to date OSX I open a terminal window and if I type the letter "e" (without quotes of course) it beeps and will not type the letter. Every other letter works just fine in terminal. ...
0
votes
1answer
29 views

Is it possible to create a service using only the shell and bypassing automator altogether?

Using automator is somewhat of a tedious task. Using the shell in the Terminal is much easier all around. Even using the "Run Shell Script" action inside automator is not the same as using the actual ...
0
votes
0answers
15 views

$PATH change won't persist [duplicate]

I looked at my $PATH and noticed that it starts with: /Applications/anaconda/bin: This doesn't seem right to me and I am not sure how it got there, so I tried to reset $PATH in terminal using: ...
1
vote
2answers
59 views

Using launchd to monitor a running program or process

I've written a simple bash script to check whether a program (supplied as its only argument) is running and send an email to a set address in the script if it's not. The script works if run on the ...
3
votes
2answers
47 views

How to Change USB Thumb icon using Terminal or Bash/other scripting language

I'm looking for a method to change USB or External Drive Icon using bash or any other command line method. I know how to manually chnage them like this I am using El Capitan
0
votes
0answers
39 views

In Terminal, how do I run a curl command to POST data?

I'm using OS X Yosemite and having trouble running curl to POST data to my local server. Below is the command I'm running and the response: localhost:myproject davea$ curl --header ...
0
votes
0answers
33 views

Attach file to Outlook 2016 email using AppleScript

I am attempting to attach a tar.gz archive of system logs to an Outlook 2016 email that gets created from another shell script. The script was modified from this one at JAMF Nation. Because the file ...
-1
votes
0answers
13 views

Adding text to a png with OS X bash but without third-party installed? [duplicate]

$ convert -bash: convert: command not found $ gm -bash: gm: command not found Is it possible to make an OS X El Capitan bash script to add text to an image (a png), without installing ...
1
vote
1answer
31 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 ...
1
vote
1answer
69 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' ...
1
vote
4answers
74 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. ...
4
votes
1answer
55 views

Using 'alias' in bash script in OSX

I write some scripting and I want to make it work on Linux and Mac. The problem is, that "Implementations of sed, readlink, zcat, etc. are different on OS X and Linux." So I tried THIS approach, but ...
0
votes
1answer
18 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 ...
0
votes
1answer
36 views

Mac OSX equal to linux time command

What's binary that will give exact result for Linux's time command flags? alias tcmd='/usr/bin/time \-f\ "CPU: %Us\tReal: %es\tRAM: %MKB"' Current time in Mac OSX for command above is: ...
0
votes
1answer
25 views

What's ls option in OS X does what ls -w 1 in Linux does, showing output in one column?

In Linux ls -w 1 shows list of files in 1 column instead of multi-column. What flag or other command will produce the same result in OS X? Current output under OS X: ls: 1: No such file or directory ...
1
vote
3answers
98 views

How to run a shell script from an AppleScript?

I am using a Mac running OSX Yosemite v.10.10.5. When I try to run my shell script from my AppleScript, I get the following error message: Error message at AppleScript Script Editor error "sh: ...
0
votes
3answers
79 views

How do I run a .sh or .command file in Terminal

I've always wanted to be able to run a script I've downloaded online directly from the Finder but just double clicking the file does not work.
0
votes
0answers
18 views

How can I auto resume background jobs upon login

I'm running a bash script over several days. When I put the laptop on sleep and log back in, the script is stopped. I have to send the kill -CONT message to the process for it to resume. Is there a ...
1
vote
2answers
42 views

Why doesn't pbpaste return cursor at new line in bash?

I run the command pbpaste in Terminal (bash) to get the result of my clipboard, but unlike other commands which leave the cursor at a new line below the previous stdout, pbpaste leaves it to the right ...
0
votes
1answer
39 views

Is there a `watch` command native to Darwin/OS X?

I have a script that I'm trying to port from Linux to Darwin/OS X. The Linux version currently depends on the watch command, which doesn't appear to be installed on Darwin/OS X by default. What's the ...
0
votes
1answer
18 views

What environment variables are set in .profile for OS X?

I accidentally overwrote my .profile file and I believe deleted my environment variables. To be honest, I don't really understand how the operating system handles environment variables. My rough ...
2
votes
1answer
55 views

/usr/local/bin/ not found by Automator and Java but exists in Terminal [duplicate]

Automator Shell Script echo $PATH eval /usr/libexec/path_helper -s echo $PATH Results: after the first echo $PATH: /usr/bin:/bin:/usr/sbin:/sbin after the second echo $PATH: ...
0
votes
0answers
95 views

El Capitan Mac: /usr/bin/login tries to run /bin/false

Just upgraded from Yosemite to El Capitan, and I started out with an Emacs problem: it wouldn't launch from the Emacs.app icon, complaining that it couldn't find /bin/false. I tracked this down to ...
2
votes
0answers
35 views

Using CTRL with bash

Coming from year on Windows, I swapped Cmd and Ctrl buttons. On bash I used to press Ctrl+A/Ctrl+E for jumping to the beginning/end of line. But, since I swapped the buttons I need press Cmd+A/Cmd+E. ...
0
votes
0answers
16 views

Odd behaviour for long commands after styling the terminal

After putting the following statements on the ~/.bash_profile file: # STYLING THE TERMINAL # References: # - ...
1
vote
1answer
155 views

Shell command or series of commands similar to the Automator action “Get Link URLs from Webpages”

I have a long list of URLs. Contained within each of these webpages, there are links I need to extract. The Automator action Get Link URLs from Webpages is a very useful action for this task. ...
1
vote
1answer
35 views

Setting up execution path in Terminal

I have no experience with using Terminal but I am trying to install a program msbayes (installation instructions here. The instructions say to set up an execution path using either $ echo 'export ...
2
votes
2answers
86 views

What is the most OSX or Darwin-like command-line experience available (without buying an expensive Mac or hauling my production machines home)?

I want to emulate the command-line experience from OSX with a small netbook and practice my skills with the comfort of this small machine. Surely Apple offers actual Darwin Links for developers or ...
1
vote
2answers
38 views

Problem with scripted account deletion syntax

I'm working on an account cleanup script module that can handle the hidden and unhidden accounts we're creating in bulk on new MacOS systems. We've kept the logic simple to start. However I keep ...
0
votes
1answer
111 views

terminal -bash: command not found

I'm trying to compile a c++ program on the Mac terminal with gcc then the source files path. I've found some short term fixes on the Internet but I want it so it works every time. Also I hardly know ...
0
votes
1answer
54 views

Why don't changes in the bashrc file work on a new terminal window?

I'm trying to add an alias to the bashrc file. Since I'm not good at this, Im' going to write all the steps I took nano ~/.bashrc The file had this in it export PATH="$PATH:$HOME/.rvm/bin" # Add ...
0
votes
1answer
73 views

Homebrew won't link git

I am trying to enable autocomplete for git on my mac (currently running El Capitan) but I am having troubles with Homebrew. So far, I have installed bash-completion and added the lines in my ...
0
votes
0answers
17 views

How to generate pdf with MS WORD 2011 from Command line?

Is there a way to call MS Word 2011 from the command line to generate pdf from DOCX or PPTX?