16 lines
320 B
Text
16 lines
320 B
Text
|
#!/bin/sh
|
||
|
# Nico Schottelius
|
||
|
# cinit: read configuration into variables
|
||
|
#
|
||
|
|
||
|
CONFS=$($(dirname $0)/cinit.get-confdir)/*
|
||
|
|
||
|
for conf in $CONFS; do
|
||
|
NAME="$(basename $conf | tr a-z A-Z)"
|
||
|
if eval test -z \$$NAME; then
|
||
|
eval $NAME="$(head -n 1 $conf)"
|
||
|
eval export $NAME
|
||
|
fi
|
||
|
# eval echo $NAME = \$$NAME
|
||
|
done
|