about summary refs log tree commit homepage
path: root/GNUmakefile
diff options
context:
space:
mode:
authorEric Wong <normalperson@yhbt.net>2010-12-24 16:32:28 -0800
committerEric Wong <normalperson@yhbt.net>2010-12-24 16:32:28 -0800
commit54cf500266b35beecb9c30b8252e72af9fafbc3e (patch)
treeac167dbb21317b27152256996e7ee34c13edc38d /GNUmakefile
parentc77066dd3c93d88ab91653244d36e51dc53e60d2 (diff)
downloadclogger-54cf500266b35beecb9c30b8252e72af9fafbc3e.tar.gz
wrongdoc eliminates JavaScript from our website and also
enables us to cut down on our management scripts/code for
supporting the project.
Diffstat (limited to 'GNUmakefile')
-rw-r--r--GNUmakefile49
1 files changed, 15 insertions, 34 deletions
diff --git a/GNUmakefile b/GNUmakefile
index a4a3301..dd2b8dc 100644
--- a/GNUmakefile
+++ b/GNUmakefile
@@ -1,7 +1,7 @@
 all:: test
 RUBY = ruby
 RAKE = rake
-GIT_URL = git://git.bogomips.org/clogger.git
+RSYNC = rsync
 
 GIT-VERSION-FILE: .FORCE-GIT-VERSION-FILE
         @./GIT-VERSION-GEN
@@ -43,7 +43,7 @@ test-pure:
 
 test: test-ext test-pure
 
-pkg_extra := GIT-VERSION-FILE NEWS ChangeLog
+pkg_extra := GIT-VERSION-FILE NEWS ChangeLog LATEST
 manifest: $(pkg_extra)
         $(RM) .manifest
         $(MAKE) .manifest
@@ -55,44 +55,25 @@ manifest: $(pkg_extra)
         cmp $@+ $@ || mv $@+ $@
         $(RM) $@+
 
-NEWS: GIT-VERSION-FILE .manifest
-        $(RAKE) -s news_rdoc > $@+
-        mv $@+ $@
-
-SINCE = 0.4.0
-ChangeLog: log_range = $(shell test -n "$(SINCE)" && echo v$(SINCE)..)
-ChangeLog: GIT-VERSION-FILE
-        @echo "ChangeLog from $(GIT_URL) ($(SINCE)..$(GIT_VERSION))" > $@+
-        @echo >> $@+
-        git log $(log_range) | sed -e 's/^/    /' >> $@+
-        mv $@+ $@
+ChangeLog: GIT-VERSION-FILE .wrongdoc.yml
+        wrongdoc prepare
 
-news_atom := http://clogger.rubyforge.org/NEWS.atom.xml
-cgit_atom := http://git.bogomips.org/cgit/clogger.git/atom/?h=master
-atom = <link rel="alternate" title="Atom feed" href="$(1)" \
-             type="application/atom+xml"/>
-
-doc: .document NEWS ChangeLog
-        rdoc -a -t "$(shell sed -ne '1s/^= //p' README)"
+doc: .document .wrongdoc.yml
+        find lib ext -type f -name '*.rbc' -exec rm -f '{}' ';'
+        $(RM) -r doc
+        wrongdoc all
         install -m644 COPYING doc/COPYING
-        install -m644 $(shell grep '^[A-Z]' .document)  doc/
-        $(RUBY) -i -p -e \
-          '$$_.gsub!("</title>",%q{\&$(call atom,$(cgit_atom))})' \
-          doc/ChangeLog.html
-        $(RUBY) -i -p -e \
-          '$$_.gsub!("</title>",%q{\&$(call atom,$(news_atom))})' \
-          doc/NEWS.html doc/README.html
-        $(RAKE) -s news_atom > doc/NEWS.atom.xml
-        cd doc && ln README.html tmp && mv tmp index.html
+        install -m644 $(shell grep '^[A-Z]' .document) doc/
 
 # publishes docs to http://clogger.rubyforge.org/
 # this preserves timestamps as best as possible to help HTTP caches out
 # git set-file-times is here: http://git-scm.org/gitwiki/ExampleScripts
 publish_doc:
-        git set-file-times
-        $(RM) -r doc
+        -git set-file-times
         $(MAKE) doc
-        rsync -av doc/ rubyforge.org:/var/www/gforge-projects/clogger/
+        -find doc/images -type f | \
+                TZ=UTC xargs touch -d '1970-01-01 00:00:03' doc/rdoc.css
+        $(RSYNC) -av doc/ rubyforge.org:/var/www/gforge-projects/clogger/
         git ls-files | xargs touch
 
 ifneq ($(VERSION),)
@@ -106,10 +87,10 @@ release_changes := release_changes-$(VERSION)
 release-notes: $(release_notes)
 release-changes: $(release_changes)
 $(release_changes):
-        $(RAKE) -s release_changes > $@+
+        wrongdoc release_changes > $@+
         $(VISUAL) $@+ && test -s $@+ && mv $@+ $@
 $(release_notes):
-        GIT_URL=$(GIT_URL) $(RAKE) -s release_notes > $@+
+        wrongdoc release_notes > $@+
         $(VISUAL) $@+ && test -s $@+ && mv $@+ $@
 
 # ensures we're actually on the tagged $(VERSION), only used for release