Jump to content
alexreg

Launching new Terminal window does not work with custom shell

Recommended Posts

In Terminal.app Preferences, I have the "Shells open with" property set to the custom "/opt/local/bin/bash" (rather than default login shell).

 

However, if I then enter something like > echo foo in Alfred, this opens a new Terminal window but does not execute the command as it should.

 

Alfred version: v2.8 (414)

Mac OS X version: 10.10.5

 

Share this post


Link to post

In Terminal.app Preferences, I have the "Shells open with" property set to the custom "/opt/local/bin/bash" (rather than default login shell).

 

However, if I then enter something like > echo foo in Alfred, this opens a new Terminal window but does not execute the command as it should.

 

Alfred version: v2.8 (414)

Mac OS X version: 10.10.5

 

Alfred uses some simple AppleScript to launch terminal commands similar to:

on alfred_script(q)
	tell application "Terminal"
		activate
		do script q
	end tell
end alfred_script

If this isn't running your default profile, you may need to customise this to tell Terminal which profile you'd like to use.

 

There are quite a few articles on Google discussing this, but this one looks pretty relevant:

 

http://apple.stackexchange.com/questions/62219/how-does-one-change-terminal-app-profile-for-all-open-tabs-using-a-keyboard-shor

 

Hope this helps! :)

 

[moving to help]

Share this post


Link to post

Hi Andrew,

 

Thanks a lot for your reply. That makes sense to me...

 

As it happens, I just found out what was causing the problem: I have a MacPorts version of bash installed, and its path is not a symlink... yet for some reason Terminal has a problem if you specify a custom shell and the path to it is not a symlink. It's not just Alfred it has problems with, but other utilities too. Anyway, the fix was easy enough, and is working well now. :)

Share this post


Link to post

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...