Skip to main content

A small drop-down terminal for i3 and sway

Project description

i3-quickterm

Packaging status

A small drop-down terminal for i3wm and sway

Features

  • use your favourite terminal emulator
  • can select a shell with dmenu / rofi
  • adapt to screen width
  • multi-monitor aware

Installation

Via pip:

pip install i3-quickterm

Or check the the repology badge above to check if it is packaged by your distribution.

Usage

When launched, it will minimize the quickterm on the current screen if there is one. Otherwise, it will either prompt the user for the shell to open or use the one supplied in argument.

If the requested shell is already opened on another screen, it will be moved on the current screen.

It is recommended to map it to an i3 binding:

# with prompt
bindsym $mod+p exec i3-quickterm
# always bring up standard shell, without the menu
bindsym $mod+b exec i3-quickterm shell

Configuration

The configuration is read from ~/.config/i3-quickterm/config.json or ~/.config/i3/i3-quickterm.json.

  • menu: the dmenu-compatible application used to select the shell
  • term: the terminal emulator of choice
  • history: a file to save the last-used shells order, last-used ordering is disabled if set to null
  • ratio: the percentage of the screen height to use
  • pos: where to pop the terminal (top or bottom)
  • shells: registered shells ({ name: command })

term can be either:

  • the name of a terminal from the supported list.
  • auto to select the first existing terminal of the list above (only to provide friendler defaults, not recommended otherwise)
  • a format string, like this one: urxvt -t {title} -e {expanded} with the correct arguments format of your terminal. Some terminals, like xfce4-terminal need the command argument to be passed as a string. In this case, replace {expanded} by {string}

menu, term, history and shell can contain placeholders for environment variables: {$var}.

Unspecified keys are inherited from the defaults:

{
    "menu": "rofi -dmenu -p 'quickterm: ' -no-custom -auto-select",
    "term": "auto",
    "history": "{$HOME}/.cache/i3-quickterm/shells.order",
    "ratio": 0.25,
    "pos": "top",
    "shells": {
        "js": "node",
        "python": "ipython3 --no-banner",
        "shell": "{$SHELL}"
    }
}

Supported terminals

  • alacritty
  • foot
  • gnome-terminal
  • kitty
  • roxterm
  • st
  • terminator
  • termite
  • urxvt
  • urxvtc
  • xfce4-terminal
  • xterm

If you'd like to add another terminal (or correct an error), please open a pull request.

Requirements

  • python >= 3.8
  • i3 >= v3.11 or sway >= 1.2
  • i3ipc-python >= v2.0.1
  • dmenu or rofi (optional)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

i3-quickterm-1.2.tar.gz (9.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

i3_quickterm-1.2-py3-none-any.whl (8.0 kB view details)

Uploaded Python 3

File details

Details for the file i3-quickterm-1.2.tar.gz.

File metadata

  • Download URL: i3-quickterm-1.2.tar.gz
  • Upload date:
  • Size: 9.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.6

File hashes

Hashes for i3-quickterm-1.2.tar.gz
Algorithm Hash digest
SHA256 ce764456a84d72fa552990b9fa3aca686535ec3899b1c20812758fcd0551f4ce
MD5 407f0e609d4a3eb077d1199c0fbfb33b
BLAKE2b-256 4de926f6784344d42c337f282795a74d2e03fbdb5fec13e41ca714fb2d7ae646

See more details on using hashes here.

File details

Details for the file i3_quickterm-1.2-py3-none-any.whl.

File metadata

  • Download URL: i3_quickterm-1.2-py3-none-any.whl
  • Upload date:
  • Size: 8.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.6

File hashes

Hashes for i3_quickterm-1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 df10d6cc333f08891a59ea0f105a8623bc4169461f63c48ef30dddc32b946d89
MD5 14400590f66412e4051101fb1d4e26cc
BLAKE2b-256 718191760bf47235161caf59a7903f56d90a3787aead09d85f2c2fd6211ac55a

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page