]> git.decadent.org.uk Git - dak.git/blob - config/debian/weekly.functions
Adjust cronscripts to end up with just one
[dak.git] / config / debian / weekly.functions
1 # -*- mode:sh -*-
2
3 function purgeempty() {
4     log "Purging empty directories in $ftpdir/pool/"
5
6     if [ ! -z "$(find $ftpdir/pool/ -type d -empty)" ]; then
7         find $ftpdir/pool/ -type d -empty | xargs rmdir;
8     fi
9 }
10
11 function gitcleanup() {
12     log "Doing git stuff"
13     cd ${public}/git/dak.git
14     git gc --prune
15     git update-server-info
16     # now workaround a git bug not honoring the setup in logs/*
17     # (fix in development, but until it reached backports.org.......)
18     chmod -R g+w logs/
19 }
20
21 function symlinks() {
22     log "Fixing symlinks in $ftpdir"
23     symlinks -d -r $ftpdir
24 }