3 # This is a genuine policy, not just one for testing.
5 # It allows anyone authorised to push to also, on demand:
6 # - wipe the repo and replace it with a new one
7 # (with --deliberately-fresh-repo)
8 # - do non-fast-forward pushes
9 # (with --deliberately-not-fast-forward)
13 case "$DGIT_DRS_DEBUG" in
14 ''|0) exec 3>/dev/null ;;
16 *) exec 3>&2; set -x ;;
25 echo >&3 "dgit-repos-policy-trusting: action=$action"
41 perl -e 'use Debian::Dgit qw(:policyflags); print '$1',"\n"'
46 case "$action//,$delibs," in
47 push//*,--deliberately-fresh-repo,*)
48 bitmask=$(( bitmask | `policyflags 'NOFFCHECK|FRESHREPO'` ))
50 push//*,--deliberately-not-fast-forward,*)
51 bitmask=$(( bitmask | `policyflags 'NOFFCHECK'` ))