AwesomeWM library for launching clients with single instance IDs
Go to file
James Reed 7f96a4f6e3
Makefile: Make rock target phony
2020-05-13 09:26:08 -06:00
rockspec Add workspaces 2019-09-16 08:12:35 -06:00
LICENSE Initial commit 2019-03-28 08:41:27 -06:00
Makefile Makefile: Make rock target phony 2020-05-13 09:26:08 -06:00
README.md Add workspaces 2019-09-16 08:12:35 -06:00
awesome-launch Add command line client 2019-08-30 17:09:49 -06:00
config.ld Add workspaces 2019-09-16 08:12:35 -06:00
init.lua Implement launch.spawn.here 2019-09-16 07:30:53 -06:00
panel.lua Implement callback arg called on client raise 2019-09-09 17:59:13 -06:00
shared.lua Separate widget into its own module 2019-09-09 14:09:09 -06:00
widget.lua Separate widget into its own module 2019-09-09 14:09:09 -06:00
workspace.lua workspace: Implement launching clients from file 2020-04-29 04:36:15 -06:00

README.md

awesome-launch

awesome-launch is a library for Awesome window manager that provides functions to spawn clients with single instance IDs using wm-launch.

Dependencies

Installation

$ git clone https://github.com/jcrd/awesome-launch.git
$ cd awesome-launch
$ luarocks make --local rockspec/awesome-launch-devel-1.rockspec

Usage

Require the library:

local launch = require("awesome-launch")

Now spawn a client:

launch.spawn("xterm", {id="xterm1"})

The new client will have these properties set:

  • single_instance_id = "xterm1"
  • cmdline = "xterm"

See the API documentation for descriptions of all functions.

Workspaces

Require the library:

local ws = require("awesome-launch.workspace")

Add a new workspace:

ws.add("code", {
  pwd = "/home/user/code",
  clients = {
    "xterm -e vim",
    {"qutebrowser", {factory="qutebrowser"}},
  }
})

A new tag named code will be created with the working directory and clients listed above.

Widget

A launchbar widget is provided to visualize pending clients.

Customize the launchbar:

launch.widget.color = beautiful.fg_focus

Create a new launchbar for the given screen:

screen.connect_signal("request::desktop_decoration", function (s)
  ...
  s.launchbar = launch.widget.launchbar {
    screen = s,
  }
  s.mywibox:setup {
    ...
    s.launchbar,
    ...
  }
end)

Command-line client

awesome-launch is a wrapper around awesome-client that can be used to launch clients from the command line with single instance IDs tracked by Awesome.

Usage

usage: awesome-launch [options] COMMAND...

options:
  -h          Show help message
  -j          Launch with firejail
  -f FACTORY  Launch via a window factory
  -i ID       The single instance ID to use
  -s          Spawn if not already running
  -r          Raise or spawn

Enable use of awesome-client by including the following in rc.lua:

require("awful.remote")

If installed via luarocks, ensure awesome-launch's location is in your PATH.

License

awesome-launch is licensed under the GNU General Public License v3.0 or later (see LICENSE).