Giter VIP home page Giter VIP logo

Comments (6)

arl avatar arl commented on May 27, 2024

yes tmux-gitbar only works with bash. When I developed it tmux didn't implement action hooks so I had to rely on $PROMPT_COMMAND to update Git status. (it was tmux 1.9).

FYI I'm currently adding the last touches to the replacement for tmux-gitbar, it relies solely on tmux hooks. The big advantage is that it is shell-independent as it's called by a hook, so tmux status bar is immediately updated when switching panes or windows. That is not the case with tmux-gitbar, you need to run something (or nothing but still press ENTER) to trigger the $PROMPT_COMMAND and updates tmux status bar.

I'm still polishing the project, in the meanwhile if you're interested, check it out at https://github.com/arl/gitstatus, it'w written in go:

  • compile gitstatus, with go go get github.com/arl/gitstatus/cmd/gitstatus
  • add this line to your tmux.conf:
set -g status-right '#(gitstatus -q -fmt tmux #{pane_current_path})'

Enjoy...

from tmux-gitbar.

botanicus avatar botanicus commented on May 27, 2024

@arl you rock! Cheers, I’ll check it out soon.

from tmux-gitbar.

jaimeibar avatar jaimeibar commented on May 27, 2024

Hi,
there's a typo in the compile command, it should be

- go get github.com/arl/gitstatus/cmd/gistatus
+ go get github.com/arl/gitstatus/cmd/gitstatus

It took me 10 minutes find out why the command was failing. :-)

Jaime

from tmux-gitbar.

arl avatar arl commented on May 27, 2024

Oups sorry!! thanks for reporting. Updated.
Anyway the repository for that tool of mine needs a bit of polishing and documentation

from tmux-gitbar.

arl avatar arl commented on May 27, 2024

Reopening for reference

from tmux-gitbar.

arl avatar arl commented on May 27, 2024

FYI the repo linked in issue #60 github.com/arl/gitstatus, will now remain what it was always supposed to be: a library to obtain git status.

I created a new repo github.com/arl/gitmux which is the real replacement for tmux-gitbar.

Tmux-gitbar is a pain in the butt to maintain, written in bash, only supports bash, and was designed at a time when tmux didn't have hooks.
gitmux on the other hand, is much simpler to maintain, to install, more powerful, comes with pre-built binaries and works everywhere where tmux works.

Come and have a look

from tmux-gitbar.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.