All Projects โ†’ AdamWagner โ†’ Stackline

AdamWagner / Stackline

Visualize yabai window stacks on macOS. Works with yabai & hammerspoon.

Programming Languages

lua
6591 projects

Projects that are alternatives of or similar to Stackline

HotSwitch-HS
Window switcher app using 2 stroke hotkey for macOS
Stars: โœญ 12 (-93.85%)
Mutual labels:  hammerspoon, window-manager
dotfiles
๐Ÿก There's no place like ~/
Stars: โœญ 59 (-69.74%)
Mutual labels:  hammerspoon, window-manager
hammerspoon
Boosts productivity and adds useful features to OSX.
Stars: โœญ 18 (-90.77%)
Mutual labels:  hammerspoon, window-manager
Spacehammer
Hammerspoon config inspired by Spacemacs
Stars: โœญ 280 (+43.59%)
Mutual labels:  hammerspoon, window-manager
Dotfiles
~ ๐Ÿญ ~
Stars: โœญ 147 (-24.62%)
Mutual labels:  hammerspoon
Dotfiles
If there is a shell, there is a way!
Stars: โœญ 112 (-42.56%)
Mutual labels:  hammerspoon
Xlambda
Xlambda: The Ultimate X Window Manager
Stars: โœญ 108 (-44.62%)
Mutual labels:  window-manager
Xwm
A tiny XCB floating window manager.
Stars: โœญ 107 (-45.13%)
Mutual labels:  window-manager
I3wm Config
my i3wm config
Stars: โœญ 196 (+0.51%)
Mutual labels:  window-manager
Dotfiles
๐Ÿ’ป macOS System Configuration with Fish, Package Control, VS Code, Repo management, Hammerspoon
Stars: โœญ 168 (-13.85%)
Mutual labels:  hammerspoon
Bsp Layout
Manage layouts in bspwm (tall and wide)
Stars: โœญ 145 (-25.64%)
Mutual labels:  window-manager
Dotfiles
Configuration files for XMonad, Emacs, NixOS, Taffybar and more.
Stars: โœญ 127 (-34.87%)
Mutual labels:  window-manager
Grout
Simple tiling window manager for Windows
Stars: โœญ 151 (-22.56%)
Mutual labels:  window-manager
Keyboard
โŒจ Toward a more useful keyboard
Stars: โœญ 1,522 (+680.51%)
Mutual labels:  hammerspoon
Alt Tab Macos
Windows alt-tab on macOS
Stars: โœญ 3,492 (+1690.77%)
Mutual labels:  window-manager
I3wsr
Change i3-wm workspace names based on content
Stars: โœญ 107 (-45.13%)
Mutual labels:  window-manager
Xmonad
The core of xmonad, a small but functional ICCCM-compliant tiling window manager
Stars: โœญ 2,253 (+1055.38%)
Mutual labels:  window-manager
Dot Hammerspoon
My personal Hammerspoon configuration - mirrored from GitLab
Stars: โœญ 165 (-15.38%)
Mutual labels:  hammerspoon
Hadlock
X window manager
Stars: โœญ 141 (-27.69%)
Mutual labels:  window-manager
Hyper Hacks
macOS Sierra hacks using some combination of Alfred 3, Karabiner-Elements, and Hammerspoon
Stars: โœญ 139 (-28.72%)
Mutual labels:  hammerspoon

stackline-logo

Version License: MIT

Visualize yabai window stacks on macOS. Works with yabai & hammerspoon.

Latest update

๐Ÿ“ฃ Update: improved configuration: please review docs for ๐Ÿ’”๏ธ breaking changes!

See changes in more detail in the changelog.

Up next

๐Ÿ› ๏ธ In progress: Refactoring for testability โ†’ Unit tests

You can find all the info below and more in the wiki.

What is stackline & why would I want to use it?

stackline adds simple, unobtrusive visual indicators to compliment yabai's window stacking functionality.

A 'stack' is a generalized subset of a tabbed UI that enables multiple macOS windows to occupy the same screen space and behave as a single unit. A stack let's a userโ€ฆ

  • add & remove windows from a stack
  • navigate between stacked windows
  • understand the contents of a stack at a glance

Stacks are a recent addition (June 2020) to the (excellent!) macOS tiling window manager koekeishiya/yabai. See yabai #203 for more info about yabai's stacking feature. Currently, yabai does not provide visual indication of a stack's active window or the inactive windows below. This makes it easy to forgot about the stacked windows that aren't visible.

Enter stackline: simple, unobtrusive visual indicators that compliment yabai window stacks.

stackline-demo

Features

  • ๐Ÿšฆ See your stacks. Window indicators show you which BSP leaves are stacks & how many windows each stack contains
  • ๐Ÿ”ฆ App icons. Toggle icons on to know exactly which apps are stacked where. Toggle icons off and get a slim minimalistic indicator that doesn't get in the way.
  • ๐Ÿง˜โ€โ™‚๏ธ๏ธ Smart positioning. Whichever mode you prefer, indicators always stay out of the way on the outside edge of the window (nearest the screen edge). stackline v0.1.55 has full support for multi-monitor setups, too.
  • ๐Ÿงฎ Always in sync. stackline keeps track of stacks as you move between spaces, resize windows, and add or remove stacks.
  • ๐Ÿ•น๏ธ Flexible control. Control stackline via shell commands, or access the instance directly via Hammerspoon.
Icon indicatorsโ€ฆ โ€ฆor minimal indicators

Getting started with stackline

Prerequisites

See wiki for example keybindings to create and navigate between stacks.

Installing stackline

  1. Clone the repo into ~/.hammerspoon/stackline
  2. Install the hammerspoon cli tool

1. Clone the repo into ~/.hammerspoon/stackline

# Get the repo
git clone https://github.com/AdamWagner/stackline.git ~/.hammerspoon/stackline

# Make stackline run when hammerspoon launches
cd ~/.hammerspoon
echo 'stackline = require "stackline.stackline.stackline"' >> init.lua
echo 'stackline:init()' >> init.lua

Now your ~/.hammerspoon directory should look like this:

โ”œโ”€โ”€ init.lua
โ””โ”€โ”€ stackline
  โ”œโ”€โ”€ bin
  โ”‚   โ””โ”€โ”€ yabai-get-stack-idx
  โ”œโ”€โ”€ conf.lua
  โ”œโ”€โ”€ stackline
  โ”‚   โ”œโ”€โ”€ configmanager.lua
  โ”‚   โ”œโ”€โ”€ query.lua
  โ”‚   โ”œโ”€โ”€ stack.lua
  โ”‚   โ”œโ”€โ”€ stackline.lua
  โ”‚   โ”œโ”€โ”€ stackmanager.lua
  โ”‚   โ””โ”€โ”€ window.lua
  โ””โ”€โ”€ lib
      โ””โ”€โ”€ โ€ฆ

2. Install the hammerspoon cli tool

  1. Ensure Hammerspoon is running
  2. Open the hammerspoon console via the menu bar
  3. Type hs.ipc.cliInstall() and hit return
Open the Hammperspoon console via the menu bar Type `hs.ipc.cliInstall()` and hit return

Finally confirm that hs is now available by entering the following in your terminal (shell):

โฏ which hs
/usr/local/bin/hs

RETRO? GO! FIDO? GO! GUIDANCEโ€ฆ

We're almost there!

# Launch yabai (or make sure it's running)
brew services start yabai

# Launch hammerspoon (or make sure it's running)
open -a "Hammerspoon"

Now, assuming you've been issuing these commands from a terminal and also have a browser window open on the same space, make sure your terminal is positioned immediately to the left of Safari and issue the following command (or use keybindings) to create a stack:

yabai -m window --stack next

Did the terminal window expand to cover the area previously occupied by Safari? Great! At this point, you should notice two app icons at the top-left corner of your terminal window, like this:

If the icons are a bit too heavy for you, you can toggle minimalist mode by turning the icons off:

hs -c 'stackline.config:toggle("appearance.showIcons")'

The minimalist stack indicator style is shown here โ†‘

See the wiki to for details about how to do this with a key binding!.

Help us get to v1.0.0!

Give a โญ๏ธ if you think (a more fully-featured version of) stackline would be useful!

Thanks to contributors!

All are welcome (actually, please help us, ๐Ÿคฃ๏ธ)! Feel free to dive in by opening an issue or submitting a PR.

@alin23 initially proposed the concept for stackline here and encouraged @AdamWagner to share the mostly-broken proof-of-concept publicly. Since then, @alin23 dramatically improved upon the initial proof-of-concept with #13, has some pretty whiz-bang functionality on deck with #17, and has been a great thought partner/reviewer.

@zweck, who, in the same thread, got the gears turning about how @alin23's idea could be implemented and also urged Adam to share his POC.

@johnallen3d for being one the first folks to install stackline, and for identifying several mistakes & gaps in the setup instructions.

@pete-may for saving folks from frustration by fixing an out-of-date command in the readme (#48)

@AdamWagner wrote the initial proof-of-concept (POC) for stackline.

โ€ฆon the shoulders of giants

Thanks to @koekeishiya without whom the wonderful yabai would not exist, and projects like this would have no reason to exist.

Similarly, thanks to @dominiklohmann, who has helped so many people make chunkwm/yabai "do the thing" they want and provides great feedback on new and proposed yabai features.

Thanks to @cmsj, @asmagill, and all of the contributors to hammerspoon for making macOS APIs accessible to the rest of us!

Thanks to the creators & maintainers of the lua utility libaries underscore.lua, lume.lua, and self.lua.

License & attribution

stackline is licensed under the โ†— MIT License, the same license used by yabai and hammerspoon.

MIT is a simple permissive license with conditions only requiring preservation of copyright and license notices. Licensed works, modifications, and larger works may be distributed under different terms and without source code.

MIT ยฉ Adam Wagner

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].