The i3 FAQ has migrated to https://github.com/i3/i3/discussions. All content here is read-only.
Ask Your Question
1

Can't open matlab from dmenu

asked 2013-09-22 14:43:20 +0000

anonymous user

Anonymous

Hi I'm pretty new to i3, but danm i have to say i love it!

But i've faced a problem, i can't open matlab through the dmenu, but if i open the terminal and type in matlab i works like a charm.

Is it possible to open it from dmenu or do i have to open it through terminal ?

Thanks in advance!

edit retag flag offensive close merge delete

3 answers

Sort by ยป oldest newest most voted
1

answered 2014-05-04 13:56:11 +0000

nicvan gravatar image

I kinda forgot about this thread But i found a solution for the problem. In /usr/bin make a script named matlab that contains this:

!#/bin/bash
/usr/local/MATLAB/R2014a/bin/matlab -desktop`

make it executables: chmod a+x matlab

not you should be able to run matlab from dmenu

edit flag offensive delete link more
1

answered 2014-01-01 17:40:59 +0000

adder gravatar image

I have issues with matlab and dmenu too. I could not launch matlab from dmenu. I partially solved the issue by putting an one-line shell script in my PATH with the line: /path/to/matlab -desktop. Now, the strange thing: If I have a window open (like an xterm) in the current workspace, then launching the above script with dmenu starts up matlab fine (albeit, in half the screen). Then I can move the matlab to a new workspace on its own. But, if I launch the above script on an empty workspace, matlab doesn't start properly and I only get a grey window.

edit flag offensive delete link more
0

answered 2013-09-22 18:27:07 +0000

joepd gravatar image

You mean dmenu_run, I suppose? Start dmenu_run from the command line, and see if there is some error.

One possibility is that the cache file that dmenu_run uses internally, somehow has not updated itself to include this application. If so, deleting the cache file will cause it to be regenerated. Look at less $(which dmenu_run) to find the location of this cache file.

If not, check if the binary is in $PATH as dmenu_run sees it.

Good luck!

edit flag offensive delete link more

Comments

Sorry for the late answer. Deleting the cahce doesn't help anything. But if i run the dmenu_run from terminal and then tries to open matlab from the dmenu_run it works like a charm. Does change anything that I had to create a symbolic link for maltab?

nicvan gravatar imagenicvan ( 2013-09-28 12:24:45 +0000 )edit

To find out what happens, make `dmenu_run` do some logging. In my version that would be `| ${SHELL:-/bin/sh} >tmp/dmenu_log 2>&1 &`. Maybe write a line in dmenu_run to the effect of `env >> tmp/dmenu_env`, as I suspect the error to be in the environment not completely set.

joepd gravatar imagejoepd ( 2013-09-29 19:43:30 +0000 )edit

BTW: What symbolic link?

joepd gravatar imagejoepd ( 2013-09-29 19:46:48 +0000 )edit

could not make the command working, it just says: bash: syntax error near unexpected token ';&' When i installed matlab i had to go to the path where it's installed and open the file there, so i had to make a symbolic link so i just should type matlab in the terminal to open it.

nicvan gravatar imagenicvan ( 2013-10-01 19:16:59 +0000 )edit

Aight... my Bigger Than signs got eaten by this site. For a solution: Add the directory where the executable of matlab lives to your PATH.

joepd gravatar imagejoepd ( 2013-10-02 18:54:46 +0000 )edit

Question Tools

Stats

Asked: 2013-09-22 14:43:20 +0000

Seen: 1,274 times

Last updated: May 04 '14