You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
11 lines
370 B
11 lines
370 B
#!/usr/bin/env bash
|
|
cd "$(dirname "$0")"
|
|
npm init -y && \
|
|
npm install --save-dev webpack webpack-cli && \
|
|
npm install tiktoken && \
|
|
jq '.scripts.build = "webpack"' package.json > package.tmp.json && \
|
|
mv package.tmp.json package.json && \
|
|
npm run build && \
|
|
mv dist/*.wasm ./tiktoken_bg.wasm && \
|
|
mv dist/* ./ && \
|
|
rm -rf dist node_modules package-lock.json package.json |