Giter VIP home page Giter VIP logo

i3-layout-scripts's Introduction

i3 Layout Save/Open

These scripts can be used to save layouts and open saved layouts in i3. For each layout, a bash script to launch the applications associated with layout is also created. Also included in this project are 'list' and 'remove' scripts to manage saved layouts.

To install:

git clone https://github.com/dschmaryl/i3-layout-scripts
cd i3-layout-scripts

Edit 'config.py' if you would like to change the default directories in which layouts and program launchers will be saved. To create the directories and test, run 'install.py':

python3 install.py

To save a workspace layout, use the following command:

python3 save.py [WORKSPACE_NUMBER] LAYOUT_NAME

If a workspace number is not specified when saving or opening layouts, the current workspace is assumed. I prefer to use a shell script to shorten this to 'save [args]'. An alias can be used, however it will not be available in dmenu since dmenu does not normally support shell aliases. My shortcut, which is named 'save' and sits in my home/bin folder, looks like:

python3 /path/to/i3-layout-scripts/save.py $1 $2

To open a saved layout, use:

python3 open.py LAYOUT_NAME [WORKSPACE_NUMBER]

When a layout is saved, and if nothing else with the same name as the layout exists in your PATH, a shortcut to open that layout is created to save some typing. These shortcuts are put in '~/.i3-layouts/bin' by default, so this folder needs to be added to your PATH. The easiest way to open a saved layout is to switch to the workspace in which you want the layout to open and then enter the name of the layout in dmenu or whatever launcher you prefer.

i3-layout-scripts's People

Contributors

dschmaryl avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.