{"id":19650959,"url":"https://github.com/tim-janik/jj-fzf","last_synced_at":"2025-04-28T16:31:07.326Z","repository":{"id":260836174,"uuid":"882483365","full_name":"tim-janik/jj-fzf","owner":"tim-janik","description":"Text UI for Jujutsu based on fzf, centering around the jj log with key bindings for common operations","archived":false,"fork":false,"pushed_at":"2025-01-30T02:16:09.000Z","size":283,"stargazers_count":103,"open_issues_count":4,"forks_count":6,"subscribers_count":3,"default_branch":"trunk","last_synced_at":"2025-04-05T09:41:58.509Z","etag":null,"topics":["bash-script","cli","command-line-tool","fzf","git","jj","jujutsu","merge","rebase","squash","terminal","tui"],"latest_commit_sha":null,"homepage":"","language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mpl-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/tim-janik.png","metadata":{"files":{"readme":"README.md","changelog":"NEWS.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":"2024-11-02T22:28:17.000Z","updated_at":"2025-04-04T05:15:06.000Z","dependencies_parsed_at":"2025-01-08T02:35:05.245Z","dependency_job_id":"673d002e-d536-4dac-91b3-50fc14067fd2","html_url":"https://github.com/tim-janik/jj-fzf","commit_stats":null,"previous_names":["tim-janik/jj-fzf"],"tags_count":5,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tim-janik%2Fjj-fzf","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tim-janik%2Fjj-fzf/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tim-janik%2Fjj-fzf/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tim-janik%2Fjj-fzf/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/tim-janik","download_url":"https://codeload.github.com/tim-janik/jj-fzf/tar.gz/refs/heads/trunk","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251345862,"owners_count":21574797,"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":["bash-script","cli","command-line-tool","fzf","git","jj","jujutsu","merge","rebase","squash","terminal","tui"],"created_at":"2024-11-11T15:04:38.700Z","updated_at":"2025-04-28T16:31:07.320Z","avatar_url":"https://github.com/tim-janik.png","language":"Shell","funding_links":[],"categories":["Shell"],"sub_categories":[],"readme":"\u003c!-- BADGES --\u003e\n[![License][mpl2-badge]][mpl2-url]\n[![Issues][issues-badge]][issues-url]\n[![Irc][irc-badge]][irc-url]\n\n\u003c!-- HEADING --\u003e\nJJ-FZF\n======\n\n![JJ-FZF Intro](https://github.com/user-attachments/assets/a4e248d1-15ef-4967-bc8a-35783da45eaa)\n**JJ-FZF Introduction:** [Asciicast](https://asciinema.org/a/684019) [MP4](https://github.com/user-attachments/assets/1dcaceb0-d7f0-437e-9d84-25d5b799fa53)\n\n\u003c!-- ABOUT --\u003e\n## About jj-fzf\n\n`JJ-FZF` is a text UI for [jj](https://martinvonz.github.io/jj/latest/) based on [fzf](https://junegunn.github.io/fzf/), implemented as a bash shell script.\nThe main view centers around `jj log`, providing previews for the `jj diff` or `jj obslog` of every revision.\nSeveral key bindings are available to quickly perform actions such as squashing, swapping, rebasing, splitting, branching, committing, abandoning revisions and more.\nA separate view for the operations log `jj op log` enables fast previews of old commit histories or diffs between operations, making it easy to `jj undo` any previous operation.\nThe available hotkeys are displayed onscreen for simple discoverability.\nThe commands and key bindings can also be displayed with `jj-fzf --help` and are documented in the wiki: [jj-fzf-help](https://github.com/tim-janik/jj-fzf/wiki/jj-fzf-help)\n\nThe `jj-fzf` script is implemented in bash-5.1, using fzf and jj with git.\nCommand line tools like sed, grep, gawk are assumed to provide GNU tool semantics.\n\n\u003c!-- USAGE --\u003e\n## Usage\n\nStart `jj-fzf` in any `jj` repository and study the keybindings.\nVarious `jj` commands are accesible through `Alt` and `Ctrl` key bindings.\nThe query prompt can be used to filter the *oneline* revision display from the `jj log` output and\nthe preview window shows commit and diff information.\nWhen a key binding is pressed to modify the history, the corresponding `jj` command with its\narguments is displayed on stderr.\n\n\u003c!-- FEATURES --\u003e\n## Features\n\n### Splitting Commits\n\nThis screencast demonstrates how to handle large changes in the working copy using `jj-fzf`.\nIt begins by splitting individual files into separate commits (`Alt+F`), then interactively splits (`Alt+I`) a longer diff into smaller commits.\nDiffs can also be edited using the diffedit command (`Alt+E`) to select specific hunks.\nThroughout, commit messages are updated with the describe command (`Ctrl+D`),\nand all changes can be undone step by step using `Alt+Z`.\n\n![Splitting Commits](https://github.com/user-attachments/assets/d4af7859-180e-4ecf-872c-285fbf72c81f)\n**Splitting Commits:** [Asciicast](https://asciinema.org/a/684020) [MP4](https://github.com/user-attachments/assets/6e1a837d-4a36-4afd-ad7e-d1ce45925011)\n\n### Merging Commits\n\nThis screencast demonstrates how to merge commits using the `jj-fzf` command-line tool.\nIt begins by selecting a revision to base the merge commit on, then starts the merge dialog with `Alt+M`.\nFor merging exactly 2 commits, `jj-fzf` suggests a merge commit message and opens the text editor before creating the commit.\nMore commits can also be merged, and in such cases, `Ctrl+D` can be used to describe the merge commit afterward.\n\n![Mergin Commits](https://github.com/user-attachments/assets/47be543f-4a20-42a2-929b-e9c53ad1f896)\n**Mergin Commits:** [Asciicast](https://asciinema.org/a/685133) [MP4](https://github.com/user-attachments/assets/7d97f37f-c623-4fdb-a2de-8860bab346a9)\n\n### Rebasing Commits\n\nThis screencast demonstrates varies ways of rebasing commits (`Alt+R`) with `jj-fzf`.\nIt begins by rebasing a single revision (`Alt+R`) before (`Ctrl+B`) and then after (`Ctrl+A`) another commit.\nAfter that, it moves on to rebasing an entire branch (`Alt+B`), including its descendants and ancestry up to the merge base, using `jj rebase --branch \u003cb\u003e --destination \u003cc\u003e`.\nFinally, it demonstrates rebasing a subtree (`Alt+S`), which rebases a commit and all its descendants onto a new commit.\n\n![Rebasing Commits](https://github.com/user-attachments/assets/d2ced4c2-79ec-4e7c-b1e0-4d0f37d24d70)\n**Rebasing Commits:** [Asciicast](https://asciinema.org/a/684022) [MP4](https://github.com/user-attachments/assets/32469cab-bdbf-4ecf-917d-e0e1e4939a9c)\n\n### \"Mega-Merge\" Workflow\n\nThis screencast demonstrates the [Mega-Merge](https://ofcr.se/jujutsu-merge-workflow) workflow, which allows to combine selected feature branches into a single \"Mega-Merge\" commit that the working copy is based on.\nIt begins by creating a new commit (`Ctrl+N`) based on a feature branch and then adds other feature branches as parents to the commit with the parent editor (`Alt+P`).\nAs part of the workflow, new commits can be squashed (`Alt+W`) or rebased (`Alt+R`) into the existing feature branches.\nTo end up with a linear history, the demo then shows how to merge a single branch into `master` and rebases everything else to complete a work phase.\n\n![Mega-Merge Workflow](https://github.com/user-attachments/assets/f944afa2-b6ea-438d-802b-8af83650a65f)\n**Mega-Merge:** [Asciicast](https://asciinema.org/a/685256) [MP4](https://github.com/user-attachments/assets/eb1a29e6-b1a9-47e0-871e-b2db5892dbf1)\n\n\u003c!-- CONTRIB --\u003e\n## Contrib Directory\n\nThe `contrib/` directory contains additional tools or scripts that complement the main jj-fzf functionality.\nThese scripts are aimed at developers and provide useful utilities for working with jj.\n\n* **jj-am.sh:** A very simple script that allows to apply patches to a jj repository.\n  `Usage: ~/jj-fzf/contrib/jj-am.sh [format-patch-file...]`\n\n* **jj-undirty.el:** A simple Emacs lisp script that automatically runs `jj status` every time a buffer is saved to snapshot file modifications.\n  `Usage: (load (expand-file-name \"~/jj-fzf/contrib/jj-undirty.el\"))`\n  This will install an after-save-hook that calls `jj-undirty` to snapshot the changes in a saved buffer in a jj repository.\n\n* **suspend-with-shell.el:** A simple Emacs lisp script that allows to suspend Emacs with a custom command.\n  ```\n  Usage:\n    ;; Suspend emacs with a custom command, without using `ioctl(TIOCSTI)`\n    (load (expand-file-name \"~/jj-fzf/contrib/suspend-with-shell.el\"))\n    ;; Suspend emacs and start jj-fzf on Ctrl+T\n    (global-set-key (kbd \"C-t\") (lambda () (interactive) (suspend-with-shell \"jj-fzf\")))\n  ```\n\n\u003c!-- LICENSE --\u003e\n## License\n\nThis application is licensed under\n[MPL-2.0](https://github.com/tim-janik/anklang/blob/master/LICENSE).\n\n\n\u003c!-- MARKDOWN LINKS \u0026 IMAGES --\u003e\n\u003c!-- https://www.markdownguide.org/basic-syntax/#reference-style-links --\u003e\n[irc-badge]: https://img.shields.io/badge/Live%20Chat-Libera%20IRC-blueviolet?style=for-the-badge\n[irc-url]: https://web.libera.chat/#Anklang\n[issues-badge]: https://img.shields.io/github/issues-raw/tim-janik/tools.svg?style=for-the-badge\n[issues-url]: https://github.com/tim-janik/tools/issues\n[mpl2-badge]: https://img.shields.io/static/v1?label=License\u0026message=MPL-2\u0026color=9c0\u0026style=for-the-badge\n[mpl2-url]: https://github.com/tim-janik/tools/blob/master/LICENSE\n\u003c!-- https://github.com/othneildrew/Best-README-Template --\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftim-janik%2Fjj-fzf","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftim-janik%2Fjj-fzf","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftim-janik%2Fjj-fzf/lists"}