Musca Commands

Musca is controlled by issuing text commands, via one of:

add

add <name>

Create a new group called name, and switch to it.

bind

bind <on/off> <Modifier>+<Key> <command>

Bind a Musca command to a key combination with on, and remove it again with off. If the argument to off is all, it clears the bound key list. The command argument is only needed for on`.

border

border <on/off>

(toggle) Turn the current frame border on and off.

catchall

catchall <on/off>

(toggle) Set the current frame as a catch-all, where all new windows will open.

client

client hints <on/off>

(toggle) Whether to respect X size hints for the current application window, such as PMinSize, PMaxSize, PResizeInc, PBaseSize, PAspect.

command

command

Launch the dmenu Musca command input.

cycle

cycle <local> <next/prev>

Cycle a hidden window into the current frame. local means cycle only windows previously displayed in the current frame. next or prev specify the direction, defaulting to next. Both arguments are optional.

dedicate

dedicate <on/off>

(toggle) Dedicate the current frame to the current app, so that no new windows will open there.

drop

drop <name/number>

Delete a group by name or by number.

dump

dump <file>

Export a description (group name and frame layout) of the current group to file.

exec

exec <command>

Execute as shell command.

focus

focus <left/right/up/down>

or

lfocus/rfocus/ufocus/dfocus

Change focus to a frame in the specified direction.

height

height <relative/pixel>

Resize frame vertically.

hook

hook <on/off> <pattern> <command>

Bind a Musca command to any other Musca command matching pattern.

hsplit

hsplit <relative/pixel>

Split frame horizontally.

kill

kill <number/name>

Politely close the client window via a close event. When the optional argument number or name is given, kill the associated window, otherwise kill the current frame. Press again to forcibly kill it.

load

load <file>

Import a description from file into the current group.

manage

manage <on/off> <name>

(toggle) Set whether the window class called name is managed or ignored.

move

move <name/number>

Move the current window to the group called name or to the group number.

name

name <name>

Rename the current group.

only

only

Remove all other frames except the current one, resizing it to full screen.

pad

pad <left> <right> <top> <bottom>

Set the current group screen padding in pixels.

quit

quit

Exit Musca.

raise

raise <number/title>

Raise and focus a window in the current group by number (order opened) or

title.

refresh

refresh

Trigger a screen refresh for the focused frame and window. Some apps dislike being resized into a frame immediately on startup and might need a nudge.

remove

remove

Remove the current frame and resize others to fill the gap.

resize

resize <left/right/up/down>

Resize the current frame in the specified direction.

run

run <file>

Execute a file consisting of Musca commands. The file must contain one command per line. Lines starting with hash # are comments and blank lines are acceptable.

say

say <text>

Display text via the method in the 'notify' setting.

screen

screen <number>

Switch to screen number. This is zero based, and should match the order in which screens are defined in xorg.conf.

set

set <setting> <value>

Set a Musca variable. See [[Settings/settings]] for a list of variable names.

shell

shell

Launch the dmenu shell command input.

show

show <settings/bindings/unmanaged/hooks/groups/frames/windows/aliases>

Output a system table for diagnostic purposes.

Note: When calling show commands in background scripts, it is best to prefix the command with silent to suppress the output also being directed to Musca's notify setting. Eg:

$ musca -c "silent show groups"

shrink

shrink <name/id>

Allow minimizing/iconifying a window. A normal raise <name/id> will restore the window.

slide

slide <left/right/up/down>

or

lslide/rslide/uslide/dslide

Move current window into the frame to the left, right, up and down respectively.

swap

swap <left/right/up/down>

or

lswap/rswap/uswap/dswap

Swap current window with the contents of the frame to the left, right, up and down respectively.

switch

switch <window/group>

Launch the dmenu window or group switcher.

undo

undo

Revert the last frame layout change.

use

use <name/number/(other)/(prev)/(next)>

Switch to a group called by its name or to a group by its number. name has precedence over number. When (other), (prev) or (next), switch to the previously focused, previous or next group respectively.

vsplit

vsplit <relative/pixel>

Split frame vertically.

width

width <relative/pixel>

Resize frame horizontally.