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

Re: [PATCH 1/2] Update the bash prompt from 'applied' instead of the obsolete 'current'

From
Karl Hasselström <kha@treskal.com>
Date
May 22, 2007, 13:29 UTC
Message-ID
<20070522132927.GA12626@diana.vm.bytemark.co.uk>
In-Reply-To
<b0943d9e0705220511u2b3ed46fg220af2cce26fef96@mail.gmail.com>
On 2007-05-22 13:11:13 +0100, Catalin Marinas wrote:
Show 16 quoted lines
> On 21/05/07, Karl Hasselström <kha@treskal.com> wrote:
>
> > My suggestion was to have a small stand-alone C program that could
> > do some operations that need to be really fast, such as
> > top/applied/unapplied. It need not have a nice user interface
> > since it's only going to be called by scripts (bash-completion and
> > the like), and it should only handle those operations that _must-
> > avoid the Python startup penalty. And for sanity reasons, it
> > should share code with stgit.
>
> There is one more case to consider - people using NFS-mounted
> directories. The applied/unapplied commands would be even slower and
> the language overhead be negligible.
>
> Another workaround would be to always generate the applied/unapplied
> files when the stack structure changes.

Yes, we could do that. These files would only be accurate when the stack was last modified with StGIT and not plain git, but that might be acceptable.

Hmm. Since the only way plain git modifies the stack is by changing HEAD (we assume the user doesn't manually mess with the patch refs), we might also write down the value of HEAD for which the applied/unapplied files are valid, so that the caller could call "stg applied" if the applied file was out of date. But that's quite a hassle to have to reimplement every time.

-- 
Karl Hasselström, kha@treskal.com
      www.treskal.com/kalle
Previous: Catalin MarinasNext: Yann Dirson
Message 12 of 15 in “Bash prompt updates”
  1. 0/2 Bash prompt updatesRobin Rosenberg, May 20, 2007
  2. 1/2 Update the bash prompt from 'applied' instead of the obsolete 'current'Robin Rosenberg, May 20, 2007
  3. Yann DirsonMay 20, 2007
  4. 1/2 Update the bash prompt from 'applied' instead of the obsolete 'current'Robin Rosenberg, May 20, 2007
  5. Karl HasselströmMay 21, 2007
  6. Catalin MarinasMay 21, 2007
  7. Karl HasselströmMay 21, 2007
  8. Karl HasselströmMay 21, 2007
  9. Catalin MarinasMay 21, 2007
  10. Karl HasselströmMay 21, 2007
  11. Catalin MarinasMay 22, 2007
  12. Karl HasselströmMay 22, 2007
  13. Yann DirsonMay 21, 2007
  14. 2/2 Don't use / as separatar since it is common i branch namesRobin Rosenberg, May 20, 2007
  15. 2/2 Don't use / as separatar since it is common i branch namesRobin Rosenberg, May 20, 2007

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.