Re: [PATCH] contrib/hooks: add sample post-receive hook using agefile

2015-08-12 Thread John Keeping
On Wed, Aug 12, 2015 at 03:41:57PM +0200, Jason A. Donenfeld wrote: > You might want to add this to > http://git.zx2c4.com/cgit/about/faq Something like this (which probably needs a bit of editing to make the tone consistent with what's already there)? -- >8 -- Subject: [PATCH] faq: add an entry

Re: [PATCH] contrib/hooks: add sample post-receive hook using agefile

2015-08-12 Thread John Keeping
Jason, did you decide not to apply this or was it just lost in the noise? [Thread starts here: http://article.gmane.org/gmane.comp.version-control.cgit/2258 ] On Tue, Dec 23, 2014 at 05:12:41PM +0100, Ferry Huberts wrote: > On 23/12/14 16:48, John Keeping wrote: > > On Tue, Dec 23, 2014 at 04:15:

Re: [PATCH] contrib/hooks: add sample post-receive hook using agefile

2015-08-12 Thread Jason A. Donenfeld
Merged. I'll review the backlog of the rest of the ML soon enough. ___ CGit mailing list CGit@lists.zx2c4.com http://lists.zx2c4.com/mailman/listinfo/cgit

Re: [PATCH] contrib/hooks: add sample post-receive hook using agefile

2015-08-12 Thread Jason A. Donenfeld
Lost in the noise. I need to allocate some time in the next few weeks to sift through the ML and apply all the patches and merge a change of my own I've sitting on for a bit. ___ CGit mailing list CGit@lists.zx2c4.com http://lists.zx2c4.com/mailman/listi

Re: [PATCH] contrib/hooks: add sample post-receive hook using agefile

2015-08-12 Thread Jason A. Donenfeld
You might want to add this to http://git.zx2c4.com/cgit/about/faq git checkout wiki vim faq ___ CGit mailing list CGit@lists.zx2c4.com http://lists.zx2c4.com/mailman/listinfo/cgit

Re: [PATCH] contrib/hooks: add sample post-receive hook using agefile

2014-12-23 Thread Ferry Huberts
On 23/12/14 16:48, John Keeping wrote: On Tue, Dec 23, 2014 at 04:15:15PM +0100, Ferry Huberts wrote: On 23/12/14 15:40, John Keeping wrote: +agefile="$(git rev-parse --git-dir)"/info/web/last-modified use $GIT_DIR here instead of rev-parse githooks(5) doesn't guarantee that GIT_DIR wil

Re: [PATCH] contrib/hooks: add sample post-receive hook using agefile

2014-12-23 Thread John Keeping
On Tue, Dec 23, 2014 at 04:15:15PM +0100, Ferry Huberts wrote: > > > On 23/12/14 15:40, John Keeping wrote: > > +agefile="$(git rev-parse --git-dir)"/info/web/last-modified > > use $GIT_DIR here instead of rev-parse githooks(5) doesn't guarantee that GIT_DIR will be set and the fact that it cur

Re: [PATCH] contrib/hooks: add sample post-receive hook using agefile

2014-12-23 Thread Ferry Huberts
On 23/12/14 15:40, John Keeping wrote: +agefile="$(git rev-parse --git-dir)"/info/web/last-modified use $GIT_DIR here instead of rev-parse + +mkdir -p "$(dirname "$agefile")" && +git for-each-ref \ + --sort=-authordate --count=1 \ + --format='%(authordate:iso8601)' \ + >"$

[PATCH] contrib/hooks: add sample post-receive hook using agefile

2014-12-23 Thread John Keeping
One of the most frequent questions on the mailing list relates to the idle time in the repository list. The answer to this is to use the "agefile" feature to calculate the time of the last change whenever the repository receives changes. Add a sample post-receive hook in a new "contrib" directory