| 1 | |
| 2 | |
| 3 | |
| 4 | |
| 5 | |
| 6 | |
| 7 | |
| 8 | |
| 9 | |
| 10 | |
| 11 | |
| 12 | |
| 13 | |
| 14 | |
| 15 | |
| 16 | |
| 17 | |
| 18 | |
| 19 | |
| 20 | |
| 21 | |
| 22 | |
| 23 | |
| 24 | |
| 25 | |
| 26 | |
| 27 | |
| 28 | |
| 29 | |
| 30 |
|
| 31 | (define-module (gnu packages tmux)
|
| 32 | #:use-module ((guix licenses) #:prefix license:)
|
| 33 | #:use-module (guix download)
|
| 34 | #:use-module (guix gexp)
|
| 35 | #:use-module (guix packages)
|
| 36 | #:use-module (guix git-download)
|
| 37 | #:use-module (guix build-system cargo)
|
| 38 | #:use-module (guix build-system cmake)
|
| 39 | #:use-module (guix build-system gnu)
|
| 40 | #:use-module (guix build-system trivial)
|
| 41 | #:use-module (guix build-system pyproject)
|
| 42 | #:use-module (gnu packages)
|
| 43 | #:use-module (gnu packages autotools)
|
| 44 | #:use-module (gnu packages bash)
|
| 45 | #:use-module (gnu packages bison)
|
| 46 | #:use-module (gnu packages check)
|
| 47 | #:use-module (gnu packages linux)
|
| 48 | #:use-module (gnu packages libevent)
|
| 49 | #:use-module (gnu packages markup)
|
| 50 | #:use-module (gnu packages ncurses)
|
| 51 | #:use-module (gnu packages pkg-config)
|
| 52 | #:use-module (gnu packages python-build)
|
| 53 | #:use-module (gnu packages python-check)
|
| 54 | #:use-module (gnu packages python-xyz)
|
| 55 | #:use-module (gnu packages sphinx)
|
| 56 | #:use-module (gnu packages ssh)
|
| 57 | #:use-module (gnu packages tls)
|
| 58 | #:use-module (gnu packages version-control))
|
| 59 |
|
| 60 | (define-public tmux
|
| 61 | (package
|
| 62 | (name "tmux")
|
| 63 | (version "3.8")
|
| 64 | (source (origin
|
| 65 | (method git-fetch)
|
| 66 | (uri (git-reference
|
| 67 | (url "https://github.com/tmux/tmux")
|
| 68 | (commit version)))
|
| 69 | (file-name (git-file-name name version))
|
| 70 | (sha256
|
| 71 | (base32
|
| 72 | "1l95pm7rwfjhnmmc3066sfgm14l842gnzscpsa28z8nwpnbb1zd6"))))
|
| 73 | (build-system gnu-build-system)
|
| 74 | (inputs
|
| 75 | (list libevent ncurses))
|
| 76 | (native-inputs
|
| 77 | (list autoconf automake bison pkg-config))
|
| 78 | (home-page "https://github.com/tmux/tmux/wiki")
|
| 79 | (synopsis "Terminal multiplexer")
|
| 80 | (description
|
| 81 | "tmux is a terminal multiplexer: it enables a number of terminals (or
|
| 82 | windows), each running a separate program, to be created, accessed, and
|
| 83 | controlled from a single screen. tmux may be detached from a screen and
|
| 84 | continue running in the background, then later reattached.")
|
| 85 | (license license:isc)))
|
| 86 |
|
| 87 | (define-public tmux-themepack
|
| 88 | (package
|
| 89 | (name "tmux-themepack")
|
| 90 | (version "1.1.0")
|
| 91 | (source (origin
|
| 92 | (method git-fetch)
|
| 93 | (uri (git-reference
|
| 94 | (url "https://github.com/jimeh/tmux-themepack")
|
| 95 | (commit version)))
|
| 96 | (sha256
|
| 97 | (base32
|
| 98 | "00dmd16ngyag3n46rbnl9vy82ih6g0y02yfwkid32a1c8vdbvb3z"))
|
| 99 | (file-name (git-file-name name version))))
|
| 100 | (build-system gnu-build-system)
|
| 101 | (arguments
|
| 102 | `(#:tests? #f |
| 103 | #:phases (modify-phases %standard-phases
|
| 104 | (delete 'configure)
|
| 105 | (delete 'build)
|
| 106 | (replace 'install
|
| 107 | (lambda* (#:key outputs #:allow-other-keys)
|
| 108 | (let* ((out (string-append
|
| 109 | (assoc-ref outputs "out")
|
| 110 | "/share/" ,name)))
|
| 111 | (copy-recursively "powerline" (string-append out "/powerline"))
|
| 112 | (for-each (lambda (file) (copy-file file (string-append out "/" file)))
|
| 113 | '("basic.tmuxtheme"
|
| 114 | "default.tmuxtheme"
|
| 115 | "themepack.tmux"))))))))
|
| 116 | (home-page "https://github.com/jimeh/tmux-themepack")
|
| 117 | (synopsis "Collection of themes for Tmux")
|
| 118 | (description
|
| 119 | "This package provides several themes for Tmux, the terminal multiplexer.")
|
| 120 | (license license:wtfpl2)))
|
| 121 |
|
| 122 | (define-public tmuxifier
|
| 123 | (package
|
| 124 | (name "tmuxifier")
|
| 125 | (version "0.13.0")
|
| 126 | (source (origin
|
| 127 | (method git-fetch)
|
| 128 | (uri (git-reference
|
| 129 | (url "https://github.com/jimeh/tmuxifier")
|
| 130 | (commit (string-append "v" version))))
|
| 131 | (file-name (git-file-name name version))
|
| 132 | (sha256
|
| 133 | (base32
|
| 134 | "1b6a1cw2mnml84k5vhbcp58kvp94xlnlpp4kwdhqw4jrzfgcjfzd"))))
|
| 135 | (build-system gnu-build-system)
|
| 136 | (arguments
|
| 137 | `(#:tests? #f
|
| 138 | #:phases (modify-phases %standard-phases
|
| 139 | (delete 'configure)
|
| 140 | (delete 'build)
|
| 141 | (replace 'install
|
| 142 | (lambda* (#:key outputs #:allow-other-keys)
|
| 143 | (let* ((out (assoc-ref %outputs "out"))
|
| 144 | (bindir (string-append out "/bin"))
|
| 145 | (share (string-append out "/share/" ,name)))
|
| 146 | (install-file "bin/tmuxifier" bindir)
|
| 147 | (substitute* (string-append bindir "/tmuxifier")
|
| 148 | (("set -e")
|
| 149 | (string-append "TMUXIFIER=" share "\nset -e")))
|
| 150 | (for-each (lambda (init-script)
|
| 151 | (install-file init-script (string-append
|
| 152 | share "/init")))
|
| 153 | '("init.sh" "init.tcsh" "init.fish"))
|
| 154 | (for-each (lambda (dir)
|
| 155 | (copy-recursively dir (string-append
|
| 156 | share "/" dir)))
|
| 157 | '("completion" "lib" "libexec"
|
| 158 | "templates"))))))))
|
| 159 | (home-page "https://github.com/jimeh/tmuxifier")
|
| 160 | (synopsis "Powerful session, window & pane management for Tmux")
|
| 161 | (description "Tmuxifier allows you to easily create, edit, and load
|
| 162 | @code{layout} files, which are simple shell scripts where you use the tmux
|
| 163 | command and helper commands provided by tmuxifier to manage Tmux sessions and
|
| 164 | windows.")
|
| 165 | (license license:expat)))
|
| 166 |
|
| 167 | (define-public python-libtmux
|
| 168 | (package
|
| 169 | (name "python-libtmux")
|
| 170 | (version "0.62.0")
|
| 171 | (source
|
| 172 | (origin
|
| 173 | (method git-fetch)
|
| 174 | (uri (git-reference
|
| 175 | (url "https://github.com/tmux-python/libtmux")
|
| 176 | (commit (string-append "v" version))))
|
| 177 | (file-name (git-file-name name version))
|
| 178 | (sha256
|
| 179 | (base32 "095k82hcklbsm4yv90pcwq1fvxs1jinwxfh31wdvak4bdj711ri5"))))
|
| 180 | (build-system pyproject-build-system)
|
| 181 | (arguments
|
| 182 | (list
|
| 183 | #:test-flags
|
| 184 | #~(list "-o" "addopts=''" |
| 185 | "-k"
|
| 186 | (string-join
|
| 187 | (map (lambda (f)
|
| 188 | (string-append "not test_" f))
|
| 189 | '("capture_pane_start" |
| 190 | "control_mode_stdout_preserves_non_ascii_output"
|
| 191 | "new_window_name_invalid_on_3_7"
|
| 192 | "hooks_dataclass"
|
| 193 | "hook_set_show_unset_cycle"
|
| 194 | "display_popup_flags"
|
| 195 | "display_popup_target_client"
|
| 196 | "display_popup_close_on_success"
|
| 197 | "new_pane_floating"))
|
| 198 | " and "))
|
| 199 | #:phases
|
| 200 | #~(modify-phases %standard-phases
|
| 201 | (add-before 'check 'configure-tests
|
| 202 | (lambda _
|
| 203 | |
| 204 | (setenv "LANG" "en_US.utf8"))))))
|
| 205 | (propagated-inputs (list procps)) |
| 206 | (native-inputs (list python-hatchling python-pytest tmux))
|
| 207 | (home-page "https://github.com/tmux-python/libtmux")
|
| 208 | (synopsis "Python API for tmux")
|
| 209 | (description
|
| 210 | "Libtmux is the tool behind @command{tmuxp}, a tmux workspace
|
| 211 | manager in Python. It creates object mappings to traverse, inspect and interact
|
| 212 | with live tmux sessions.")
|
| 213 | (license license:expat)))
|
| 214 |
|
| 215 | (define-public tmux-xpanes
|
| 216 | (package
|
| 217 | (name "tmux-xpanes")
|
| 218 | (version "4.2.0")
|
| 219 | (source (origin
|
| 220 | (method git-fetch)
|
| 221 | (uri (git-reference
|
| 222 | (url "https://github.com/greymd/tmux-xpanes")
|
| 223 | (commit (string-append "v" version))))
|
| 224 | (file-name (git-file-name name version))
|
| 225 | (sha256
|
| 226 | (base32
|
| 227 | "0k37zswn6s9iclm9yasil9jhy768qn9fv3m489irfwrx1vc8lp9w"))))
|
| 228 | (build-system trivial-build-system)
|
| 229 | (inputs
|
| 230 | (list bash))
|
| 231 | (arguments
|
| 232 | `(#:modules ((guix build utils))
|
| 233 | #:builder
|
| 234 | (begin
|
| 235 | (use-modules (guix build utils))
|
| 236 | (setenv "PATH" (string-append (assoc-ref %build-inputs "bash") "/bin"))
|
| 237 | (copy-recursively (assoc-ref %build-inputs "source") ".")
|
| 238 | (substitute* "bin/xpanes"
|
| 239 | (("/bin/bash") (which "bash")))
|
| 240 | (install-file "bin/xpanes" (string-append %output "/bin"))
|
| 241 | (install-file "man/xpanes.1" (string-append %output "/man/man1"))
|
| 242 | #t)))
|
| 243 | (home-page "https://github.com/greymd/tmux-xpanes")
|
| 244 | (synopsis "Tmux based terminal divider")
|
| 245 | (description "This package provides tmux-based terminal divider.
|
| 246 |
|
| 247 | @code{xpanes} or @code{tmux-xpanes} (alias of @code{xpanes}) commands have
|
| 248 | following features:
|
| 249 |
|
| 250 | @itemize
|
| 251 | @item Split tmux window into multiple panes.
|
| 252 | @item Build command lines & execute them on the panes.
|
| 253 | @item Runnable from outside of tmux session.
|
| 254 | @item Runnable from inside of tmux session.
|
| 255 | @item Record operation log.
|
| 256 | @item Flexible layout arrangement for panes.
|
| 257 | @item Display pane title on each pane.
|
| 258 | @item Generate command lines from standard input (Pipe mode).
|
| 259 | @end itemize")
|
| 260 | (license license:expat)))
|
| 261 |
|
| 262 | (define-public tmux-plugin-resurrect
|
| 263 | (let ((commit "a2ddfb96b94bb64a7a2e3f5fa2a7c57dce8ad579")
|
| 264 | (revision "0"))
|
| 265 | (package
|
| 266 | (name "tmux-plugin-resurrect")
|
| 267 | (version (git-version "0" revision commit))
|
| 268 | (source (origin
|
| 269 | (method git-fetch)
|
| 270 | (uri (git-reference
|
| 271 | (url "https://github.com/tmux-plugins/tmux-resurrect/")
|
| 272 | (commit commit)))
|
| 273 | (file-name (git-file-name name version))
|
| 274 | (sha256
|
| 275 | (base32
|
| 276 | "1gc8z99na1d4scn2kq4alwyn43h3r7ykz9bkhcypjh8iri6dsl0c"))))
|
| 277 | (build-system trivial-build-system)
|
| 278 | (arguments
|
| 279 | `(#:modules ((guix build utils))
|
| 280 | #:builder (begin
|
| 281 | (use-modules (guix build utils))
|
| 282 | (let ((out (string-append %output
|
| 283 | "/share/tmux-plugins/resurrect/")))
|
| 284 | (mkdir-p out)
|
| 285 | (copy-recursively (assoc-ref %build-inputs "source") out)))))
|
| 286 | (synopsis "Restore tmux environment after system restart")
|
| 287 | (description
|
| 288 | "This plugin goes to great lengths to save and restore all the details
|
| 289 | from your tmux environment. Here's what's been taken care of:
|
| 290 |
|
| 291 | @itemize
|
| 292 | @item all sessions, windows, panes and their order
|
| 293 | @item current working directory for each pane
|
| 294 | @item exact pane layouts within windows (even when zoomed)
|
| 295 | @item active and alternative session
|
| 296 | @item active and alternative window for each session
|
| 297 | @item windows with focus
|
| 298 | @item active pane for each window
|
| 299 | @item \"grouped sessions\" (useful feature when using tmux with multiple monitors)
|
| 300 | @item programs running within a pane! More details in the restoring programs doc.
|
| 301 | @end itemize
|
| 302 |
|
| 303 | Optional:
|
| 304 |
|
| 305 | @itemize
|
| 306 | @item restoring vim and neovim sessions
|
| 307 | @item restoring pane contents
|
| 308 | @end itemize")
|
| 309 | (home-page "https://github.com/tmux-plugins/tmux-resurrect/")
|
| 310 | (license license:expat))))
|
| 311 |
|
| 312 | (define-public tmux-plugin-continuum
|
| 313 | (let ((commit "3e4bc35da41f956c873aea716c97555bf1afce5d")
|
| 314 | (revision "0"))
|
| 315 | (package
|
| 316 | (name "tmux-plugin-continuum")
|
| 317 | (version (git-version "0" revision commit))
|
| 318 | (source (origin
|
| 319 | (method git-fetch)
|
| 320 | (uri (git-reference
|
| 321 | (url "https://github.com/tmux-plugins/tmux-continuum/")
|
| 322 | (commit commit)))
|
| 323 | (file-name (git-file-name name version))
|
| 324 | (sha256
|
| 325 | (base32
|
| 326 | "1py8qfs2f93hkxhk039m813bjgcs5k54si662gx05g3czqy06pb7"))))
|
| 327 | (build-system trivial-build-system)
|
| 328 | (arguments
|
| 329 | `(#:modules ((guix build utils))
|
| 330 | #:builder (begin
|
| 331 | (use-modules (guix build utils))
|
| 332 | (let ((out (string-append %output
|
| 333 | "/share/tmux-plugins/continuum/")))
|
| 334 | (mkdir-p out)
|
| 335 | (copy-recursively (assoc-ref %build-inputs "source")
|
| 336 | out)))))
|
| 337 | (synopsis "Continuous saving of tmux environment")
|
| 338 | (description
|
| 339 | "Features:
|
| 340 |
|
| 341 | @itemize
|
| 342 | @item continuous saving of tmux environment
|
| 343 | @item automatic tmux start when computer/server is turned on
|
| 344 | @item automatic restore when tmux is started
|
| 345 | @end itemize
|
| 346 |
|
| 347 | Together, these features enable uninterrupted tmux usage. No matter the
|
| 348 | computer or server restarts, if the machine is on, tmux will be there how you
|
| 349 | left it off the last time it was used.")
|
| 350 | (home-page "https://github.com/tmux-plugins/tmux-continuum/")
|
| 351 | (license license:expat))))
|
| 352 |
|
| 353 | (define-public tmux-plugin-mem-cpu-load
|
| 354 | (package
|
| 355 | (name "tmux-plugin-mem-cpu-load")
|
| 356 | (version "3.8.2")
|
| 357 | (source (origin
|
| 358 | (method git-fetch)
|
| 359 | (uri (git-reference
|
| 360 | (url "https://github.com/thewtex/tmux-mem-cpu-load")
|
| 361 | (commit (string-append "v" version))))
|
| 362 | (sha256
|
| 363 | (base32
|
| 364 | "041hd6s6prk63r121yggxmzhbp40h6r04mrby0q51x43lfgvmvw3"))
|
| 365 | (file-name (git-file-name name version))))
|
| 366 | (build-system cmake-build-system)
|
| 367 | (synopsis "CPU, RAM, and load monitor for use with tmux")
|
| 368 | (description "This package provides a lightweight program for system
|
| 369 | monitoring in the status line of tmux.
|
| 370 |
|
| 371 | The memory monitor displays the used and available memory.
|
| 372 |
|
| 373 | The CPU usage monitor outputs a percent CPU usage over all processors. It
|
| 374 | also displays a textual bar graph of the current percent usage.
|
| 375 |
|
| 376 | The system load average is also displayed.")
|
| 377 | (home-page "https://github.com/thewtex/tmux-mem-cpu-load")
|
| 378 | (license license:asl2.0)))
|
| 379 |
|
| 380 | (define-public tmux-plugin-sessionizer
|
| 381 | (package
|
| 382 | (name "tmux-plugin-sessionizer")
|
| 383 | (version "0.4.4")
|
| 384 | (source
|
| 385 | (origin
|
| 386 | (method url-fetch)
|
| 387 | (uri (crate-uri "tmux-sessionizer" version))
|
| 388 | (file-name (string-append name "-" version ".tar.gz"))
|
| 389 | (sha256
|
| 390 | (base32 "0fwdc8jyx9fab442c6zsl3yn8nh1s5h35g97cgqhyp3blxl6h9ix"))
|
| 391 | (snippet #~(begin
|
| 392 | (use-modules (guix build utils))
|
| 393 | (substitute* "Cargo.toml"
|
| 394 | (("\"vendored-openssl\"")
|
| 395 | ""))))))
|
| 396 | (build-system cargo-build-system)
|
| 397 | (arguments
|
| 398 | (list
|
| 399 | #:install-source? #f
|
| 400 | #:modules
|
| 401 | '((guix build cargo-build-system)
|
| 402 | (guix build utils)
|
| 403 | (ice-9 match))
|
| 404 | #:phases
|
| 405 | #~(modify-phases %standard-phases
|
| 406 | (add-after 'install 'install-extras
|
| 407 | (lambda* (#:key native-inputs #:allow-other-keys)
|
| 408 | (for-each
|
| 409 | (match-lambda
|
| 410 | ((shell . path)
|
| 411 | (mkdir-p (in-vicinity #$output (dirname path)))
|
| 412 | (let ((binary
|
| 413 | (if #$(%current-target-system)
|
| 414 | (search-input-file native-inputs "bin/tms")
|
| 415 | (in-vicinity #$output "bin/tms"))))
|
| 416 | (with-output-to-file (in-vicinity #$output path)
|
| 417 | (lambda _
|
| 418 | (invoke binary "--generate" shell))))))
|
| 419 | '(("bash" . "share/bash-completion/completions/tms")
|
| 420 | ("elvish" . "share/elvish/lib/tms")
|
| 421 | ("fish" . "share/fish/vendor_completions.d/tms.fish")
|
| 422 | ("zsh" . "share/zsh/site-functions/_tms"))))))))
|
| 423 | (native-inputs
|
| 424 | (append
|
| 425 | (if (%current-target-system)
|
| 426 | (list this-package)
|
| 427 | '())
|
| 428 | (list pkg-config)))
|
| 429 | (inputs
|
| 430 | (cons* openssl
|
| 431 | libgit2-1.8
|
| 432 | libssh2
|
| 433 | (cargo-inputs 'tmux-plugin-sessionizer)))
|
| 434 | (home-page "https://github.com/jrmoulton/tmux-sessionizer")
|
| 435 | (synopsis "Fuzzy find Git repositories and open them as Tmux sessions")
|
| 436 | (description
|
| 437 | "Tmux Sessionizer is a command-line tool to fuzzy find all the Git
|
| 438 | repositories in a list of specified folders and open them as a new tmux session.
|
| 439 | For @code{git worktrees}, this tool opens all checked out worktrees as new windows.")
|
| 440 | (license license:expat)))
|
| 441 |
|
| 442 | (define-public opentmux
|
| 443 | (package
|
| 444 | (name "opentmux")
|
| 445 | (version "0.1")
|
| 446 | (home-page "https://codeberg.org/opentmux/opentmux")
|
| 447 | (source (origin
|
| 448 | (method git-fetch)
|
| 449 | (uri (git-reference
|
| 450 | (url home-page)
|
| 451 | (commit (string-append "v" version))))
|
| 452 | (file-name (git-file-name name version))
|
| 453 | (sha256
|
| 454 | (base32
|
| 455 | "0b8gy3acysw0vi28g4327iq5cj3zsv9cvvx21iqnkcvk6hqvyrnc"))))
|
| 456 | (build-system gnu-build-system)
|
| 457 | (inputs
|
| 458 | (list libevent ncurses))
|
| 459 | (native-inputs
|
| 460 | (list autoconf automake bison lowdown pkg-config))
|
| 461 | (synopsis "Terminal multiplexer")
|
| 462 | (description
|
| 463 | "opentmux is fork of tmux, before AI was introduced. tmux is a terminal
|
| 464 | multiplexer: it enables a number of terminals (or windows), each running a
|
| 465 | separate program, to be created, accessed, and controlled from a single screen.
|
| 466 | tmux may be detached from a screen and continue running in the background, then
|
| 467 | later reattached.")
|
| 468 | (license license:isc)))
|