diff options
| author | Dean Smith | 2012-06-12 16:40:57 +0100 |
|---|---|---|
| committer | Max Howell | 2012-07-30 13:23:19 -0400 |
| commit | fe32e6343d25df14012378ddecd8e84d84adc7ec (patch) | |
| tree | 933b0d6da20eed50ab9657b59862eefea6886665 /Library/Homebrew/utils.rb | |
| parent | 0c237a86797eabd181b5dd889e8981ab1648320e (diff) | |
| download | brew-fe32e6343d25df14012378ddecd8e84d84adc7ec.tar.bz2 | |
Invoke non interactive shell from brew edit
Fixes Homebrew/homebrew#12779. Closes Homebrew/homebrew#12784.
utils.rb invokes bash as a non interactive shell to run the editor
when you run brew edit.
Non-interactive shells are not intended to capture user input and for running scripts. Whilst the invocation of the editor is a script the actual editor is intended for accept user input so this is an issue with brew and not emacs.
This causes issues with emacs which has different behaviors when not running under an interactive shell.
Signed-off-by: Max Howell <mxcl@me.com>
Diffstat (limited to 'Library/Homebrew/utils.rb')
| -rw-r--r-- | Library/Homebrew/utils.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Library/Homebrew/utils.rb b/Library/Homebrew/utils.rb index 4099c4825..b7158ae98 100644 --- a/Library/Homebrew/utils.rb +++ b/Library/Homebrew/utils.rb @@ -178,7 +178,7 @@ def exec_editor *args # Invoke bash to evaluate env vars in $EDITOR # This also gets us proper argument quoting. # See: https://github.com/mxcl/homebrew/issues/5123 - system "bash", "-c", which_editor + ' "$@"', "--", *args + system "bash", "-i", "-c", which_editor + ' "$@"', "--", *args end # GZips the given paths, and returns the gzipped paths |
