{"id":18910108,"url":"https://github.com/cretezy/i3-back","last_synced_at":"2025-04-15T06:31:11.020Z","repository":{"id":84554939,"uuid":"606581802","full_name":"Cretezy/i3-back","owner":"Cretezy","description":"An i3/Sway utility to switch focus to your last focused window. Alt+Tab in i3","archived":false,"fork":false,"pushed_at":"2025-03-16T03:38:32.000Z","size":48,"stargazers_count":48,"open_issues_count":5,"forks_count":7,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-03-28T17:11:52.352Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Cretezy.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-02-25T23:07:33.000Z","updated_at":"2025-03-16T03:38:36.000Z","dependencies_parsed_at":null,"dependency_job_id":"e9549463-2e0b-41e2-8284-1823abde82c1","html_url":"https://github.com/Cretezy/i3-back","commit_stats":{"total_commits":19,"total_committers":2,"mean_commits":9.5,"dds":"0.10526315789473684","last_synced_commit":"41dec080677ce13eceb9a7d4c1c0cdf86dfebbf8"},"previous_names":[],"tags_count":8,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Cretezy%2Fi3-back","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Cretezy%2Fi3-back/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Cretezy%2Fi3-back/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Cretezy%2Fi3-back/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Cretezy","download_url":"https://codeload.github.com/Cretezy/i3-back/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":249020746,"owners_count":21199609,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-08T09:41:11.570Z","updated_at":"2025-04-15T06:31:10.997Z","avatar_url":"https://github.com/Cretezy.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# i3-back\n\nAn [i3](https://i3wm.org/)/[Sway](https://swaywm.org/) utility to switch focus to your last focused window. Allows for behavior similar to Alt+Tab on other desktop environments.\n\n**Features**:\n\n- Can switch between your 2 most recent windows\n  - Runs a daemon (background process) to listen for focus changes and sets a mark\n- Supports i3 and Sway\n- Supports floating windows\n- Can be binded to any key through i3's `bindsym`\n\n## Demo\n\nhttps://user-images.githubusercontent.com/2672503/221384419-3d62413d-8987-4147-82bc-5e87cea8bb90.mp4\n\n## Installation\n\ni3-back requires i3/Sway. It is written in Rust. It can be installed through many method:\n\n- [Cargo](https://doc.rust-lang.org/cargo/getting-started/installation.html) (Rust's package manager) package:\n\n  ```\n  cargo +nightly install i3-back\n  ```\n\n- Arch Linux from the AUR ([i3-back-bin](https://aur.archlinux.org/packages/i3-back-bin)):\n\n  ```\n  yay -S i3-back-bin # Or with paru or other AUR wrappers\n  # Or manually: https://wiki.archlinux.org/title/Arch_User_Repository#Installing_and_upgrading_packages\n  ```\n\n- Debian/Ubuntu as a `deb` from [GitHub releases](https://github.com/cretezy/i3-back/releases)\n\n- Binary from [GitHub releases](https://github.com/cretezy/i3-back/releases)\n\n### Setup\n\nIn your i3/Sway configuration (`~/.config/i3/config`/`~/.config/sway/config`):\n\n```\n# Start the daemon which listens to focus changes and sets _back mark\nexec --no-startup-id ~/.cargo/bin/i3-back\n\n# Bind a switch key, which focuses the previously focused window\nbindsym $mod+Tab [con_mark=_back] focus\n```\n\nReplace `~/.cargo/bin` with wherever the i3-back binary is placed if not installed through Cargo.\n\n## Options\n\nAll options are optional. Options are passed to `i3-back` as flags.\n\nExample `exec` with options:\n\n```\nexec --no-startup-id ~/.cargo/bin/i3-back --debug --mark _last\n```\n\nAvailable options:\n\n- `--help`/`-h`: See help text. Also see `--version`\n- `--mark \u003cMARK\u003e`/`-m \u003cMARK\u003e`: Change the default `_back` mark name. Make sure to update your switcher bind's `con_mark` to match\n- `--debug`/`-d`: Print extra debugging information\n\nExample `i3-back --help`:\n\n```\nAn i3/Sway utility to switch focus to your last focused window. Allows for behavior similar to Alt+Tab on other desktop environments.\n\nUsage: i3-back [OPTIONS]\n\nOptions:\n  -m, --mark \u003cMARK\u003e  Change the name of the mark to set [default: _back]\n  -d, --debug        Print extra debugging information\n  -h, --help         Print help\n  -V, --version      Print version\n```\n\n## How it works\n\nThe daemon (`i3-back`) listen for i3 window events (through i3's socket, from the `I3SOCK` environment variable).\nWhen a window event is received, i3-back records the previously focused window ID.\nWhen the previous focus has changed, it sets the `_back` [mark](https://i3wm.org/docs/userguide.html#vim_like_marks) (or whichever is configured through the `--mark` flag) to the last focused window.\n\nWhen the switch bind is called (through i3's `bindsym`), it focuses the mark set by the daemon.\n\n## Prior work\n\n- [`@nicarran`](https://github.com/nicarran)'s [snippet](https://github.com/i3/i3/issues/838#issuecomment-481531210)\n- [`@lbonn`](https://github.com/lbonn)'s [`i3-focus-last`](https://github.com/lbonn/i3-focus-last)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcretezy%2Fi3-back","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcretezy%2Fi3-back","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcretezy%2Fi3-back/lists"}