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

Advice on strategy for "temporary" commits

From
DTDavid Tweed <david.tweed@gmail.com>
Date
Mar 8, 2007, 14:39 UTC
Message-ID
<e1dab3980703080639i4c553e89nb931c2aea45b023b@mail.gmail.com>
Hi,

I've been working with my system taking automatic hourly git snapshots of (filtered portions of) my home directory for a couple of months. Being able to look back to what files looked like mid-afternoon yesterday, or on 18 Nov, is proving modestly useful. However, I'm thinking about adding "temporary" commits every ten minutes which then get discarded after 5 hours-ish (in addition to the long-term archival hourly commits). This is motivated by the desire to have finer granularity for testing/bisecting short-term regressions but not having ridiculously fine-grained changes clogging up the archive long-term. (I'm aware that with the commits being primarily taken on a timed basis I'll have more non-compiling changes than is usual in a repository, so that this may not turn out to be useful in practice.)

Looking through the git docs, it looks like the most natural way of doing this is to make the 10-min commits (via cron & tagging them under a special tag "temporary commits only" directory) and then use

git-rebase --onto start-tag end-tag branch

every so often (via cron again) to chop the older temporary commits between start-tag and end-tag out of the database.

However, I'm not remotely expert on all the other things you can do with git, so I'm just checking there's not a way considered better/safer (eg, a separate branch or repository).

Many thanks for any insight,
-- 
cheers, dave tweed__________________________
david.tweed@gmail.com
Rm 124, School of Systems Engineering, University of Reading.
Details are all that matters; God dwells there, and you never get to
see Him if you don't struggle to get them right. -- Stephen Jay Gould
Next: Alex Riesen
Message 1 of 7 in “Advice on strategy for "temporary" commits”
  1. David TweedMar 8, 2007
  2. Alex RiesenMar 8, 2007
  3. J. Bruce FieldsMar 8, 2007
  4. David TweedMar 8, 2007
  5. Mark WoodingMar 8, 2007
  6. Jakub NarebskiMar 9, 2007
  7. David TweedMar 11, 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.