mirror of
https://github.com/go-sylixos/elvish.git
synced 2024-12-14 02:57:52 +08:00
19 lines
251 B
Plaintext
Executable File
19 lines
251 B
Plaintext
Executable File
#!/usr/bin/env elvish
|
|
|
|
out = ./embedded_modules.go
|
|
|
|
{
|
|
echo "package eval"
|
|
echo "var embeddedModules = map[string]string{"
|
|
|
|
for f [*.elv] {
|
|
print '"'$f[:-4]'": `'
|
|
cat $f | sed 's/`/`+"`"+`/g'
|
|
echo '`,'
|
|
}
|
|
|
|
echo "}"
|
|
} > $out
|
|
|
|
gofmt -w $out
|