Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent) Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
22 lines
440 B
Bash
Executable file
22 lines
440 B
Bash
Executable file
#!/bin/bash
|
|
set -e
|
|
|
|
API_TOKEN="${FORGEJO_TOKEN:-$1}"
|
|
|
|
if [ -z "$API_TOKEN" ]; then
|
|
echo "Usage: $0 <api_token>"
|
|
echo "Or set FORGEJO_TOKEN environment variable"
|
|
exit 1
|
|
fi
|
|
|
|
echo "Building package..."
|
|
uv run python -m build
|
|
|
|
echo "Publishing to forgejo..."
|
|
uv run twine upload \
|
|
--repository-url https://git.infra.er-gpt.ru/api/packages/pypi \
|
|
--username __token__ \
|
|
--password "$API_TOKEN" \
|
|
dist/*
|
|
|
|
echo "Done!"
|