-   Linux - Software (
-   -   [Awesome] How do I get the menu to use aliases? (

BeaverusIV 08-27-2010 12:56 AM

[Awesome] How do I get the menu to use aliases?
I currently have:


alias pms='wmname LG3D && pms'
So that PS3 Media Server has a GUI and not just a blank window... this works if run from terminal but not when typed in my menu... how can I get Awesome to use the alias? Using:


{ "PS3 Media Server", "wmname LG3D && pms" }
doesn't work.

David the H. 08-27-2010 06:26 AM

Aliases are a feature of your shell, and are usually only loaded for interactive shells at that.

I don't know anything about awesome, but if its command launcher behaves like most of the others, it likely handles the commands internally on its own rather than invoking a shell to do it. There's probably some kind of "run in shell" option, but I'll bet even that gets invoked non-interactively.

So unless it has some sort of built-in aliasing system of its own, probably your only option is to create a special menu item or script with your commands in it and launch that.

BeaverusIV 08-28-2010 12:42 AM

I found the solution; use 'awful.util.spawn_with_shell.


{ "PS3 Media Server", function () awful.util.spawn_with_shell("wmname LG3D && pms") end }

All times are GMT -5. The time now is 06:00 AM.