[xmonad] How to prefix workspace names with numbers?

Jacek Generowicz jacek.generowicz at cern.ch
Tue Oct 9 09:18:50 CEST 2012

Pablo Olmos de Aguilera C. writes:

> First, I'd question myself why I would want to create workspaces on
> the fiy :P,

Really !?

> and then "keep them" enough time to make your issue relevant. I always
> imagined dynamicworkspaces as a complement to create "short-lived"
> workspaces.

DynamicWorkspaces has made my use of computers bearable.

*Everything* I do, gets its own Dynamic workspace:

+ Letter to Aunt Mabel: open a new workspace; 
+ fiddle with my XMonad config: new workspace;
+ Order a book/toaster/monitor: new workspace;
+ try to solve my dropped network connection problem: new workspace;
+ install some software: new workspace;
+ fix bug #7364: new workspace;
+ draw a new logo for the Worm Appreciation Society: new workspace;
+ the new course I am writing: its own workspace
+ topic I want to read up on and experiment with for the new course: new
  workspace. In reality, many workspaces, because I will want to
  investigate many different topics.

The fact that I can have all windows related to some activity grouped
together on a workspace, not interfering with those related to other
activities, combined with the ability to SWITCH TO THAT WORKSPACE IN
UNDER A SECOND, regardless of whether it was last visited seconds ago or
weeks ago, is one of the hugest boons to my productivity I have ever

Having these workspaces have names I make up on the fly, makes it very
easy to remember what is what.

The real world has this habit of not letting me finish whatever I am
doing without interruption. I have to task switch between many things.
Some tasks last mere seconds, some take weeks or months. The ability to
have a workspace dedicated to each of these tasks and to switch between
the contexts they create at almost zero cost, and the concomitant
confidence this brings in being able to switch away from some context in
the knowledge that when I get around to resuming this task (be it 5
seconds from now or 3 weeks from now) everything will be waiting for me
exactly as I left it, is what make my modern use of computers bearable.

> In my case I keep 7 "fixed" WS:

Frankly, I don't see how you manage with only 7 workspaces. 

> 1:terms, 2:web, 3:coding, 4:files, 5:media, 6:various, 7:im.

Coding? Just one workspace for coding? You can seriously fit *all* the
windows related to *all* the coding tasks you are currently working on,
on to a *sigle* workspace?  Remember that 'currenly' includes

+ the speculative refactoring of the frobnicator in the Fubar project,
  which you've been playing with in your spare moments over the last week
+ the showstopping segfault that your PHB/lover/most important client
  *needs* solving *this minute*.
+ the new feature you have been working on as your main coding task for
  the last 2 days
+ that damned bug #7364 which you've been chipping away at for the last
+ your experiments with the new feature introduced by the latest release
  of some language/package you use
+ the code samples you are creating to help new people joining the Barfoo
  project, get going quickly

Each of these is likely to contain

+ Editor window
+ compilation/evaluation/running/tsting window(s)
+ documentation window
+ miscellaneous related web search window

All that, one one 'coding' workspace? Really?

(If you don't like coding, similar examples can be made in whatever
domain you like.)

Files? Various? Aah, takes me back to the Dark Ages before I got my
hands on DynamicWorkspaces.

Working with a window manager without Dynamic Workspaces, to me, looks
like working on a filesystem without mkdir and rmdir, where you
determine the directories you get when you configure your OS. 

> They are called that way, so it's easy to use the number to jump
> between them 

I have 3 keys for workspace navigation (and some related ones for screen

+ Select workspace by name Automatically switches when unique starting
  substring is entered: this means that most workspace switches take just
  two keystrokes. And I don't have to remember that, say, files is 4: I
  just have to remember that files starts with 'f' (or, in extremis, 'fi').
+ Select most recently used invisible workspace (very useful).
+ Cycle through (I almost never use this one)

On most of these I also have the following modifiers

+ SHIFT: send the focused window to the target workspace (keep focus on
  the source workspace)
+ CONTROL: carry the focused window to the target workspace (move focus
  to the target workspace)

You can pry my DynamicWorkspaces from my cold dead fingers.

More information about the xmonad mailing list