Chimrod / i3_workspaces

Workspace manager for i3-wm
63 stars 1 forks source link

Exec on i3 config not working #2

Closed raynan222 closed 5 years ago

raynan222 commented 5 years ago

Already tried:

exec_always --no-starup-id i3_workspaces
exec --no-starup-id i3_workspaces
exec i3_workspaces
exec_always i3_workspaces
exec --no-startup-id i3-msg 'workspace term; exec i3_workspaces'

PS: Even with an bash script that exec i3_workspaces its not working

Chimrod commented 5 years ago

Hi !

Thanks a lot for your interest and getting so far !

If you build the code with make the binary should be in ./_build/default/src/i3_workspaces.exe can you check it ?

raynan222 commented 5 years ago

Found here

/home/raynan/.opam/default/.opam-switch/build/i3_workspaces.0.1/_build/default/src

But i didnt used the make command. I did installed the i3_workspaces with opam and the command on terminal was already working Where should i use the make?

Chimrod commented 5 years ago

Ok, if you installed with opam, just run whereis i3_workspaces in bash should give you the rigth path. Something like that :

$ whereis i3_workspaces 
i3_workspaces: ~/.opam/4.07.0+flambda/bin/i3_workspaces
raynan222 commented 5 years ago
$ whereis i3_workspaces
i3_workspaces: /home/raynan/.opam/default/bin/i3_workspaces
Chimrod commented 5 years ago

Good ! just run the binary directly, or copy it somewhere in you $PATH.

raynan222 commented 5 years ago

exec --no-starup-id /home/raynan/.opam/default/bin/i3_workspaces Still not working.

This problem is kind odd since i can run on terminal the command i3_workspaces and the program work as intended but the i3 config file cant run as intended.

Even something like this works bindsym $mod+F9 exec /home/raynan/.opam/default/bin/i3_workspaces

Chimrod commented 5 years ago

This is very weird.

Can you add a redirection to log the output like this :

exec --no-startup-id "/home/raynan/.opam/default/bin/i3_workspaces > /tmp/i3_workspaces.log"

and check the log file for some messages ? I did not log a lot, but you should get a message if the config file is not found, or when you are switching to an undefined workspace.

The program try to find the configuration file in $XDG_CONFIG_HOME/i3_workspaces/config or $HOME/.config/i3_workspaces/config. You can try to set the config file with -c /path/to/your/config

It is supposed to work out of the box, thank you for the time you take with this problem !

raynan222 commented 5 years ago

exec --no-startup-id "/home/raynan/.opam/default/bin/i3_workspaces > /tmp/i3_workspaces.log" after this suddenly the program starts to work then i try this: exec --no-startup-id "/home/raynan/.opam/default/bin/i3_workspaces" well its working now... but this make no sense to me i do have few programs with the path on my config file and none of this was necessary the "" to work.

Chimrod commented 5 years ago

I agree, this should not be necessary. I've added the quote in the example because of the redirecting >, but I do not have myself quoted the command in my configuration file.

Anyway, it is a good thing if it is working for you now. I let you close the ticket