stagit-hook

Maintain stagit post-update git hooks
Log | Files | Refs | README

stagit-hook.1 (1234B)


      1 .Dd October 19, 2025
      2 .Dt STAGIT-HOOK 1
      3 .Os
      4 .Sh NAME
      5 .Nm stagit-hook
      6 .Nd Git hook to automatically run stagit
      7 .Sh SYNOPSIS
      8 .Nm
      9 .Op Ar repo ...
     10 .Sh DESCRIPTION
     11 The 
     12 .Nm
     13 utility generates repository pages with
     14 .Xr stagit 1
     15 and repository index pages with
     16 .Xr stagit-index 1 .
     17 When used without arguments,
     18 .Nm
     19 determines the repository pages to generate with the
     20 .Ev GIT_DIR
     21 environment variable.
     22 If
     23 .Ev GIT_DIR
     24 isn't set, it only generates an index page.
     25 .Pp
     26 .Sh FILES
     27 .Bl -tag -width Ds
     28 .It Pa /etc/stagit-hook
     29 .Xr stagit-hook 5
     30 configuration file.
     31 .El
     32 .Sh EXIT STATUS
     33 .Ex -std
     34 .Sh EXAMPLES
     35 .Pp
     36 Manually initialize
     37 repository and index pages for
     38 .Pa example :
     39 .Pp
     40 .Dl $ stagit-hook example
     41 .Pp
     42 Setup stagit-hook for all repositories with the
     43 .Pa git-daemon-export-ok
     44 file:
     45 .Bd -offset indent -literal
     46 $ mkdir -p ~/.git/hooks
     47 $ echo '#!/bin/sh
     48 test -e "$GIT_DIR"/git-daemon-export-ok &&
     49 	exec stagit-hook' > ~/.git/hooks/post-update
     50 $ chmod +x ~/.git/hooks/post-update
     51 $ git config --global core.hooksPath ~/.git/hooks
     52 $ doas sh -c 'echo hasfile git-daemon-export-ok > /etc/stagit-hook'
     53 .El
     54 .Sh SEE ALSO
     55 .Xr stagit 1 ,
     56 .Xr stagit-index 1 ,
     57 .Xr githooks 5 ,
     58 .Xr stagit-hook 5
     59 .Sh AUTHORS
     60 .An Jacob R. Edwards Aq Mt jacob@jacobedwards.org