#!/bin/sh

set -ex

svn delete ckb
svn commit --message 'console-setup: remove Keyboard/ckb, will add the most recent version from CVS'

cvs -d  :pserver:anoncvs@cvs.freedesktop.org:/cvs/xlibs login
cvs -z3 -d :pserver:anoncvs@cvs.freedesktop.org:/cvs/xlibs export -D 1 xkbdesc

cd xkbdesc/rules
make -f ../../ckb.Makefile base
make -f ../../ckb.Makefile base.xml
cp base xorg
cp base.xml xorg.xml

cd ../..

mkdir ckb
for f in keycodes rules symbols; do
    mv xkbdesc/$f ckb/
done
rm -r xkbdesc

rm -r `find ckb -name 'Makefile.am' -o -name '*.in'`
rm -r `find ckb -name '*.sh' -o -name '*.pl'`
rm -r `find ckb -name '.??*'`
rm -r `find ckb -name '*.part' -o -name 'HDR'`

svn add ckb
svn commit --message 'console-setup: add the most recent version of Keyboard/ckb'
