elvish/eval/builtin_modules.bash
Qi Xiao c37a51c2ed Implement the use builtin.
This addresses #135.
2016-02-16 23:15:12 +01:00

19 lines
240 B
Bash
Executable File

#!/bin/bash
out=./builtin_modules.go
{
echo "package eval"
echo "var builtinModules = map[string]string{"
for f in *.elv; do
echo -n "\"${f%.elv}\": \`"
cat $f | sed 's/`/``/g'
echo '`,'
done
echo "}"
} > $out
gofmt -w $out