gradio/scripts/gh_action_pypi.sh
aliabid94 2a113b20f3
Release 3 1 3a (#1931)
* changes

* changes
2022-08-02 08:17:47 -07:00

27 lines
590 B
Bash
Executable File

#!/bin/bash
cd "$(dirname ${0})/.."
source scripts/helpers.sh
pnpm_required
aws_required
# You should first run `upload_to_pypi.sh` to update the version number and
# pull the latest version of the code.
new_version="$(cat gradio/version.txt)"
GRADIO_VERSION=$new_version
rm -rf gradio/templates/frontend
rm -rf gradio/templates/cdn
cd ui
pnpm i
pnpm build
pnpm build:cdn
cd ..
aws s3 cp gradio/templates/cdn "s3://gradio/${new_version}/" --recursive
cp gradio/templates/cdn/index.html gradio/templates/frontend/share.html
rm -r dist/*
rm -r build/*
python3 setup.py sdist bdist_wheel