1
0
Fork 0
codesnap.nvim/scripts/build_generator.sh

19 lines
292 B
Bash
Executable File

#!/bin/bash
source ./scripts/check_os.sh
(cd ./generator; cargo build $1)
lib_suffix="so"
target="debug"
if [[ $os =~ "mac" ]]; then
lib_suffix="dylib"
fi
if [[ $1 =~ "release" ]]; then
target="release"
fi
cp -rf ./generator/target/$target/libgenerator.$lib_suffix lua/generator.so