ghc/ghc-gen_contents_index-cron-batch.patch
Jens Petersen e89f5f0022 add a cronjob for haddock indexing and disable gen_contents_index by default
gen_contents_index is run with --batch by cronjob, otherwise does nothing.
This avoids overhead of running of re-indexing each time
a ghc-*-devel package is installed, updated, or removed.
2010-11-04 18:41:32 +10:00

24 lines
724 B
Diff

diff -u ghc-6.12.3/libraries/gen_contents_index\~ ghc-6.12.3/libraries/gen_contents_index
--- ghc-6.12.3/libraries/gen_contents_index~ 2010-09-14 13:03:12.000000000 +1000
+++ ghc-6.12.3/libraries/gen_contents_index 2010-11-04 18:26:00.000000000 +1000
@@ -21,6 +21,6 @@
HADDOCK_ARGS="$HADDOCK_ARGS $HADDOCK_ARG"
done
;;
-*)
+--batch)
HADDOCK=/usr/bin/haddock
# We don't want the GHC API to swamp the index
@@ -32,6 +32,9 @@
HADDOCK_ARGS="$HADDOCK_ARGS $HADDOCK_ARG"
done
;;
+ *)
+ HADDOCK=/bin/true
+ tty -s && echo Run with '--batch' to index package haddock docs.
esac
# Now create the combined contents and index pages
Diff finished. Thu Nov 4 18:26:04 2010