diff options
author | Jonas Smedegaard <dr@jones.dk> | 2007-10-17 02:09:03 +0000 |
---|---|---|
committer | Jonas Smedegaard <dr@jones.dk> | 2007-10-17 02:09:03 +0000 |
commit | 78755e38ac0ab20cec1665473e9b4a9b7eeb9cb4 (patch) | |
tree | ef761f8d110de835ec58800e71ef53d2b7898dba /localikiwikicreatesite | |
parent | 5624b726aadc9fa6cee855008849136b248b849e (diff) |
Create content repository within config ditto.
Diffstat (limited to 'localikiwikicreatesite')
-rwxr-xr-x | localikiwikicreatesite | 22 |
1 files changed, 20 insertions, 2 deletions
diff --git a/localikiwikicreatesite b/localikiwikicreatesite index c49942e..abcb063 100755 --- a/localikiwikicreatesite +++ b/localikiwikicreatesite @@ -9,7 +9,7 @@ host=$1 srchost=${2:-source.$host} SRCDIR=~/private_webdata/$host/content -CFGDIR=~/private_webdata/$host/backend +CFGDIR=~/private_webdata/$host DESTDIR=~/public_websites/$host DESTSRCDIR=~/public_websites/$srchost @@ -50,6 +50,7 @@ git push --all ( cd $CFGDIR git init +echo /content > .gitignore git add . git commit -m "initial commit" git remote add origin $DESTSRCDIR/backend.git @@ -57,7 +58,7 @@ git config branch.master.merge refs/heads/master git push --all ) -## Adjust backend +## Adjust backend and add Makefile for further customization perl -pi -e ' s,^(\s*)#?(srcdir\s*=>\s*\")(.*)(\"\,\s*),$1$2'$SRCDIR'$4,; s,^(\s*)#?(destdir\s*=>\s*\")(.*)(\"\,\s*),$1$2'$DESTDIR'$4,; @@ -68,6 +69,23 @@ perl -pi -e ' ( cd $CFGDIR git add ikiwiki.setup +cat <<EOF >$CFGDIR/Makefile +#underlays = basewiki smiley templates +underlays = templates +#locale = danish +master = master +#master = master-LOCALE + +all: $(underlays) + +$(underlays): + mkdir $@ + cd $@ && git init + cd $@ && git remote add -f -t $(master:LOCALE=$(locale)) -m $(master:LOCALE=$(locale)) origin http://source.jones.dk/ikiwiki_$@.git + cd $@ && git merge origin +EOF +echo /Makefile > .gitignore +git add Makefile git commit -m "Setup local paths" git push ) |