• Stars
    star
    637
  • Rank 70,257 (Top 2 %)
  • Language
    Shell
  • License
    MIT License
  • Created over 10 years ago
  • Updated about 1 month ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

A run-or-raise application switcher for any X11 desktop

jumpapp

A run-or-raise application switcher for any X11 desktop

Build Status

The idea is simple โ€” bind a key for any given application that will:

  • launch the application, if it's not already running, or
  • focus the application's most recently opened window, if it is running.

Pressing the key again will cycle to the application's next window, if there's more than one.

In short, jumpapp is probably the fastest way for a keyboard-junkie to switch between applications in a modern desktop environment. Once installed, all you have to do is configure the key bindings you want to use:

Settings Example

Synopsis

Usage: jumpapp [OPTION]... COMMAND [ARG]...

Jump to (focus) the existing window for an application, if it's running.
Otherwise, launch COMMAND (with optional ARGs) to start the application.

Options:
  -r -- cycle through windows in reverse order
  -f -- force COMMAND to launch if process found but no windows found
  -m -- if a single window is already open and in focus - minimize it
  -n -- do not fork into background when launching COMMAND
  -N -- don't launch if no window is found
  -p -- always launch COMMAND when ARGs passed
        (see Argument Passthrough in man page)
  -L -- list matching windows for COMMAND and quit
  -t NAME -- process window has to have NAME as the window title
  -c NAME -- find window using NAME as WM_CLASS (instead of COMMAND)
  -i NAME -- find process using NAME as the command name (instead of COMMAND)
  -w -- only find the applications in the current workspace
  -R -- bring the application to the current workspace when raising
        (the default behaviour is to switch to the workspace that the
        application is currently on)
  -C -- center cursor when raising application

Installation

Ubuntu, Debian and Friends

sudo apt-get install build-essential debhelper git pandoc shunit2
git clone https://github.com/mkropat/jumpapp.git
cd jumpapp
make deb
sudo dpkg -i jumpapp*all.deb
# if there were missing dependencies
sudo apt-get install -f

Fedora and Friends

git clone https://github.com/mkropat/jumpapp.git
cd jumpapp
make rpm
sudo yum localinstall jumpapp*.noarch.rpm

Arch linux and Friends

yaourt -S aur/jumpapp-git

From Source

git clone https://github.com/mkropat/jumpapp.git
cd jumpapp
make && sudo make install

Argument Passthrough (-p option)

Many applications keep track of what windows they have open so that if you run the command again, it will interact with the existing application window instead of launching a new instance of the application.

Take Firefox, for example. If you already have a Firefox window open and you run firefox https://github.com/, Firefox won't start a new instance. What it does is open a new tab in the existing window and browse to the URL you passed.

Especially in the case of Desktop Entry files, we want to preserve this behavior. With jumpapp -p COMMAND [ARGs]..., when you include one or more ARGs, COMMAND is always executed in order to pass the ARGs to the running application. But if no ARGs are included, jumpapp will behave normally.

A Wrapper Around wmctrl(1)

All the heavy lifting is done by Tomรกลก Stรฝblo's powerful wmctrl. You must have it installed to use jumpapp.

jumpapp was built for the GNOME desktop environment. There's a good chance though that it'll work on any window manager supported by wmctrl.

XBindKeys

If your desktop environment doesn't offer a way to bind keys to commands โ€” or if it's too limited โ€” take a look at XBindKeys.

Example .xbindkeysrc:

"jumpapp chromium"
  control + alt + c

"jumpapp -r chromium"
  shift + control + alt + c

"jumpapp firefox"
  control + alt + f

"jumpapp -r firefox"
  shift + control + alt + f

"jumpapp gnome-terminal"
  control + alt + t

"jumpapp -r gnome-terminal"
  shift + control + alt + t

jumpappify-desktop-entry(1)

jumpapp ships with a helper utility:

Usage: jumpappify-desktop-entry SOMEFILE.desktop

Given a desktop entry file (*.desktop), output a new desktop entry file that
wraps the application's `Exec` in a call to jumpapp(1).

EXAMPLES

    jumpappify-desktop-entry /usr/share/applications/chromium-browser.desktop \
        > ~/.local/share/applications/chromium-browser.desktop

Or convert multiple in one go:

    for entry in /usr/share/applications/{firefox,gnome-terminal}.desktop; do
        target=~/".local/share/applications/$(basename "$entry")"
        jumpappify-desktop-entry "$entry" >"$target"
    done

Continue On Your Path To Keyboard Nirvana

Uninstall jumpapp

Ubuntu, Debian and Friends

sudo apt remove jumpapp

More Repositories

1

dapper-invoice

A billable-time invoice featuring style over substance
TeX
197
star
2

sslfie

Generate self-signed x.509 certificates for use with SSL/TLS
Shell
170
star
3

sh-realpath

A portable, pure shell implementation of realpath
Shell
91
star
4

MlkPwgen

Secure random password generator for .NET and PowerShell
C#
60
star
5

WebSocketDemo

C#
51
star
6

TidyDesktopMonster

Prevent shortcuts from cluttering your desktop ever again
C#
22
star
7

vim-tt

Task timer for Vim
Vim Script
17
star
8

vim-dwiw2015

Minimalist Vim distribution
PowerShell
14
star
9

standalone-dovecot-imap

Keep a local IMAP mirror, painlessly
Shell
13
star
10

vim-uniformity

Safely make whitespace across your project consistent
Vim Script
12
star
11

.NET-Snippets

Miscellaneous code for the .NET framework.
C#
10
star
12

secure-random-password

Generate passwords using a cryptographically-strong source of randomness
JavaScript
10
star
13

vim-ezguifont

Set and adjust the font in a cross-platform way. Supports gVim and all the Neovim GUIs.
Vim Script
8
star
14

is-shell-portable

Shell
8
star
15

BetterWin32Errors

A better interface to the constants defined in winerror.h
C#
6
star
16

jekyll-pages

Self-host your GitHub Pages website.
Shell
4
star
17

luks-mount

Teach mount(8) to open LUKS containers directly
Shell
3
star
18

jumpapp-win32

Jump to another application. Always. (Windows Version)
C#
2
star
19

focus-history

JavaScript
1
star
20

presentation-db-versioning

DB Versioning: it doesn't have to be hard
HTML
1
star
21

presentation-codemash-2018

JavaScript
1
star
22

morris9

TypeScript
1
star
23

barrier

Barrier synchronization implementation for general scripting.
JavaScript
1
star
24

mlk-dlnt

1
star
25

base64urldecoder

JavaScript
1
star
26

AsyncContextFlowStudy

C#
1
star
27

dotfiles

Shell
1
star
28

MlkFileHasher

Simple, stand-alone file hashing utility for Windows
C#
1
star
29

download-integrity-service

Shell
1
star
30

scratch

1
star
31

transit-hackathon

1
star
32

self-decrypt

JavaScript
1
star
33

ShortcutFile

C#
1
star
34

PSSnippets

PowerShell
1
star
35

PowershellAstWriter

C#
1
star
36

form-rel-noopener

HTML
1
star
37

OnScreenGamepad

work in progress
C++
1
star
38

presentation-push-architecture

HTML
1
star
39

VSPerformanceTracker

Visual Studio extension for optimizing development time
C#
1
star
40

phonehome

JavaScript
1
star
41

GetPodcastLink

C#
1
star
42

vim-jumpthere

Lightweight project switcher
Vim Script
1
star
43

test-kitchen-hyperv-poc

Test Kitchen With Hyper-V Proof of Concept
1
star
44

StoryLine

Startup Weekend Blacksburg 2014
JavaScript
1
star
45

mkropat.github.io

SCSS
1
star
46

password-site

JavaScript
1
star
47

WebDeployPackagePoc

JavaScript
1
star
48

vim-gautosession

Vim Script
1
star
49

WindsorTransitiveDependencyOverrideMWE

C#
1
star
50

kappa

messin around
JavaScript
1
star
51

MlkDiskWiper

Smalltalk
1
star
52

presentation-js-strict-mode

They why and how of JS strict mode
HTML
1
star
53

win32-disk-studies

Various examples of how to use the Win32 API and what kind of information you can pull from them
C++
1
star
54

RouteHandlerHttpModule

Find out what ASP.NET MVC controller or Web Forms page handled a given route
C#
1
star
55

RackspaceCloudOfficeApiClient

C#/.NET client library for the Rackspace Cloud Office API
1
star
56

hestrx

Hex editor plugin for Vim
Python
1
star
57

jekyll-theme-antisocial

Drop-in replacement for Minima featuring Medium-inspired typography
HTML
1
star
58

presentation-whats-a-dynamic

HTML
1
star
59

ClientSideFormsAuthPoc

C#
1
star
60

presentation-chef-workshop

HTML
1
star
61

New-PersistentWorld

PowerShell
1
star
62

bloggit

Go
1
star
63

social-media-sandbox-audit

JavaScript
1
star
64

fetch-redirect-study

HTML
1
star
65

Invoke-RsCloudOfficeRequest

PowerShell client for the Rackspace Cloud Office API
1
star