[Date Index][Thread Index]
[Date Prev][Date Next][Thread Prev][Thread Next]

Re: a few questions on using wml

> The Debian web pages are in the process of being converted to using
> wml. In the process I have come across a few things I haven't been
> able to figure out. Is it possible that there are things wml can't
> do? :)

Really cool! I'd like to take a look at the way you set it up (wml,
build system).
> Since I want the .html files in a different directory from the source
> a shebang path is used in the files, e.g. #!wml -o ../debian.org/%BASE.html.en
> What is actually desired is to use a variable to make it easier to move
> things around later, i.e. #!wml -o $(HTMLDIR)/%BASE.html.en where the
> variable is set in a .wmlrc file. Is this possible?

I spent a few days trying out different "web build systems" I had
decided on "chakotay" until I ran across wml, and I ended up with this
hybrid Makefile (I'm not using wmk).


HTML = $(shell find . -name "*.wsml" | cut -c3- | sed "s/.wsml/.html/g")

all : $(HTML)
        @echo Done Compiling

clean :
        rm -f `find . -name "*.html" -print`
        rm -f `find . -name "core" -print`
        rm -f `find . -name "*~" -print`
        rm -f `find . -name "imgsizer*" -print`

%.html : %.wsml
        wml -D ROOT~. -E weblint -n -o$@ $<


Very simplistic, unfortunetly it doesn't handle dependancies :(
Any, you can see that "*.wsml" are my source files that are to be
turned into *.html.  I use *.whml for includes, etc...

My point :), you can change the %.html : %wsml block to do whatever
(directed output, movement, whatever)... It's a little more flexible
than wmk (although I honestly haven't looked far into wmk).

David Duffey              (785)395-4807
311 Marlatt Hall          dduffey@ksu.edu
Manhattan KS 66506-1800

Website META Language (WML)                www.engelschall.com/sw/wml/
Official Support Mailing List                   sw-wml@engelschall.com
Automated List Manager                       majordomo@engelschall.com