aboutsummaryrefslogtreecommitdiff
path: root/xorg-server/xkbdata.src/rules/merge.sh
blob: 8dfde55463a1ba27b14f7cfc0145d569ff719f4c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#!/bin/bash

DEST=$1
shift

if [ -z "$HDR" ]; then
    HDR="HDR"
fi

basename=`basename $0`
echo "// DO NOT EDIT THIS FILE - IT WAS AUTOGENERATED BY $basename FROM rules/*.part" >$DEST

for i in $*; do
  if [ "$i" == "$HDR" ] || [ "$i" == "HDR" ]; then
    echo >> $DEST;
    read hdr
    echo "$hdr" >> $DEST
  else
    cat $i >> $DEST;
  fi
done < $HDR