update-website.mk make script ready

Jeroen Coumans jeroen at linuxfromscratch.org
Wed Aug 11 07:48:12 PDT 2004

Anderson Lizardo said the following on 11-08-2004 01:24:
> Hi guys,
> Finally, update-website.mk is working fine. It only recreates the files whose 
> dependencies were modified, or that were removed. This way, only the actual 
> changed files are rsynced.


> The overall "usual" update process (e.g. after a news item is added) is pretty 
> quick, and actually what is slowing down it a lot is the hints tarball 
> creation and other patches/hints-related stuff (which should be moved to 
> their respective post-commit scripts as soon as our post-commit script is 
> up).


> I've already created a small hook script, located 
> at /home/lizardo/scripts/update-website-hook.sh, that will be called by 
> subversion right after a commit. This script will be moved to a more standard 
> location (possibly /usr/bin) after the tests.

Agreed. It might be a good idea to use a "caller"-script though. At 
work, I did it like this:

# [1] REPOS-PATH (the path to this repository)
# [2] REV (the number of the revision just committed)

/usr/local/bin/post-commit-X "$1" "$2" >> /var/log/subversion/X-${2}.log 

This also captures the output of the post-commit script so you can debug 
it (there's no other way to capture the output, unfortunately).

> There is also a property attached to the repository's root dir, called 
> "targetdir", which should be used to setup where the rendered website tree is 
> located. I was not sure where to attach this property so I chose a location 
> that will not change even with the repository reorganization. Let me know if 
> you guys want it on another location. For now keep it with its current value, 
> until we feel the post-commit process is working fine.

That's good, we can easily change it after the final migration.

> So, can I enable the post-commit script to continue the tests? It should not 
> affect the current website in any way.

As far as I'm concerned, go ahead! Excellent work, btw. :-)

Jeroen Coumans

More information about the website mailing list