git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: Auto-refresh git-gui

From
VEVictor Engmark <victor.engmark@terreactive.ch>
Date
Jan 5, 2012, 08:03 UTC
Message-ID
<20120105080322.GD3484@victor>
In-Reply-To
<20120104163338.GA27567@ecki.lan>
On Wed, Jan 04, 2012 at 05:33:40PM +0100, Clemens Buchacher wrote:
Show 9 quoted lines
> Hi Victor,
> 
> On Wed, Jan 04, 2012 at 10:15:47AM +0100, Victor Engmark wrote:
> >
> > Is there some way to make `git-gui` rescan automatically when anything
> > in the repository changes?
> 
> How about doing it each time git gui gets focus? Or if that's to
> much do it only if it gets focus _and_ the index has changed?

Ideally (like in jEdit) this should be configurable. In Options -> General of jEdit, there are the following settings:

"If open files are changed on disk", with options:
* do nothing
* prompt
* automatically reload and notify user
* autoreload without notification
"Check for file change upon", with options:
* application focus
* application focus, visiting the buffer or saving any buffer
* visiting the buffer or saving any buffer
* visiting or saving the buffer
* saving the buffer
Based on this, I guess we could use the following settings:
"When repository changes", with options:
* do nothing [This could optionally disable the next setting]
* prompt
* rescan and notify user
* rescan without notification
"Check for repository changes", with options:
* always [Could be implemented with something like `inotifywait -rm`]
* upon application focus
* upon staging, unstaging, committing or pushing

I think I can see use cases for all these options, although it might be a bit much to chew for a first iteration.

-- 
Victor Engmark
terreActive AG
Kasinostrasse 30
CH-5001 Aarau
Tel: +41 62 834 00 55
Fax: +41 62 823 93 56
www.terreactive.ch

Wir sichern Ihren Erfolg - seit 15 Jahren
Previous: Clemens BuchacherNext: Uri Okrent
Message 3 of 4 in “Auto-refresh git-gui”
  1. Victor EngmarkJan 4, 2012
  2. Clemens BuchacherJan 4, 2012
  3. Victor EngmarkJan 5, 2012
  4. Uri OkrentJan 10, 2012

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.