You are not logged in.

#1 2013-08-21 14:07:14

chap
Member
Registered: 2013-07-08
Posts: 11

[SOLVED] mux not executing bin files.

Hi, i'm experiencing a problem with tmux.

For example, I have a bin file in my /home/user/bin folder called imgur, i can run it on gnu-screen or on a normal terminal but i can't run it while in tmux, can someone help me? Thanks!

Last edited by chap (2013-08-21 19:01:24)

Offline

#2 2013-08-21 14:15:09

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 30,547
Website

Re: [SOLVED] mux not executing bin files.

What error do you get?

If it's a command not found I'd suspect your PATH is being reset (or not being set).


"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman

Offline

#3 2013-08-21 14:32:40

chap
Member
Registered: 2013-07-08
Posts: 11

Re: [SOLVED] mux not executing bin files.

Trilby wrote:

What error do you get?

If it's a command not found I'd suspect your PATH is being reset (or not being set).

I get "zsh: command not found: imgur", how can i solve?

Offline

#4 2013-08-21 15:06:26

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 30,547
Website

Re: [SOLVED] mux not executing bin files.

Set your PATH variable.

From within a normal terminal, and a tmux session, run the following commands and post their output here:

echo $SHELL
echo $PATH

"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman

Offline

#5 2013-08-21 15:35:57

chap
Member
Registered: 2013-07-08
Posts: 11

Re: [SOLVED] mux not executing bin files.

Trilby wrote:

Set your PATH variable.

From within a normal terminal, and a tmux session, run the following commands and post their output here:

echo $SHELL
echo $PATH

Normal term:

~ » echo $SHELL
/usr/bin/zsh
~ » echo $PATH
/home/chap/bin:/home/chap/.local/bin:/home/chap/.local/sbin:/usr/local/bin:/usr/local/sbin:/usr/bin:/usr/sbin:/bin:/sbin:/usr/bin/site_perl:/usr/bin/vendor_perl:/usr/bin/core_perl

tmux:

~ » echo $SHELL
/usr/bin/zsh
~ » echo $PATH
/usr/local/sbin:/usr/local/bin:/usr/bin:/usr/bin/site_perl:/usr/bin/vendor_perl:/usr/bin/core_perl

Offline

#6 2013-08-21 15:44:53

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 30,547
Website

Re: [SOLVED] mux not executing bin files.

Where do you set your PATH variable?  I also asked about your shell as well in case you had a different shell in and out of tmux, but as they are both zsh, they'd both read the zshrc and other zsh configs.

Occasionally there will be problems when one *appends* to PATH in a shell rc file, as it will then be read multiple times, but that is not the case here.

If you don't know where you set your PATH variable, check your zshrc, and/or check files listed in

grep PATH ~/.* 2>/dev/null

But right now it looks like your custom PATH settings are not being applied, so knowing where you add those would be the most useful bit of information.  Hence my first question: where have you set PATH?

Last edited by Trilby (2013-08-21 15:45:14)


"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman

Offline

#7 2013-08-21 19:00:59

chap
Member
Registered: 2013-07-08
Posts: 11

Re: [SOLVED] mux not executing bin files.

Trilby wrote:

Where do you set your PATH variable?  I also asked about your shell as well in case you had a different shell in and out of tmux, but as they are both zsh, they'd both read the zshrc and other zsh configs.

Occasionally there will be problems when one *appends* to PATH in a shell rc file, as it will then be read multiple times, but that is not the case here.

If you don't know where you set your PATH variable, check your zshrc, and/or check files listed in

grep PATH ~/.* 2>/dev/null

But right now it looks like your custom PATH settings are not being applied, so knowing where you add those would be the most useful bit of information.  Hence my first question: where have you set PATH?

Thanks for your help, i set the same PATH variable in and out tmux and now everything works, marking the thread as solved!

Offline

Board footer

Powered by FluxBB