From e51a3772b5e312900ea416740e14195df7cf4c22 Mon Sep 17 00:00:00 2001 From: Shou Ya Date: Wed, 2 Aug 2017 12:09:05 +0800 Subject: [PATCH] solution to the problem 'tpm returned 127' See issue #67 for more discussion --- docs/tpm_not_working.md | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/docs/tpm_not_working.md b/docs/tpm_not_working.md index 87d2998..bfa14ac 100644 --- a/docs/tpm_not_working.md +++ b/docs/tpm_not_working.md @@ -78,3 +78,19 @@ subdirectories): ```bash find ~/.tmux -type d -name '.git*' -prune -o -type f -print0 | xargs -0 dos2unix ``` + +
+ +> '~/.tmux/plugins/tpm/tpm' returned 127 (on macOS, w/ tmux installed using brew) + +Related: [issue #67](https://github.com/tmux-plugins/tpm/issues/67) + +This problem is because tmux's `run-shell` command runs a shell which doesn't read from user configs, thus tmux installed in `/usr/local/bin` will not be found. + +The solution is to insert the following line: + +``` +set-environment -g PATH "/usr/local/bin:/bin:/usr/bin" +``` + +before any `run-shell`/`run` commands in `~/.tmux.conf`.