blob: b111f9b4847bb4e688fdfdc7eb1aa27339789123 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
|
#!/usr/bin/env sh
mode="$1"
name="$2"
boilerplates="$HOME/.boilerplates"
if [ "${mode}" = "" ] || [ "${name}" = "" ]; then
echo "Not enough parameters"
exit 1
fi
if [ "${mode}" = "clj" ]; then
lein new app "$name"
cp "$boilerplates/$mode/run" "$name"
rm -rf "$name/CHANGELOG.md" "$name/LICENSE" "$name/README.md" "$name/doc/"
elif [ "${mode}" = "md" ] || [ "${mode}" = "tex" ] || [ "${mode}" = "ms" ]; then
cp "$boilerplates/txt/$mode.$mode" "$name.$mode"
else
cp -r "$boilerplates/$mode" "$name" || echo "Something went wrong"
fi
|