Skip to content

Commit feef2c2

Browse files
committed
updated publish_gtoolkit_bridge_PyPI.sh
1 parent 22e41e3 commit feef2c2

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed
Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,24 @@
11
#!/bin/bash
22

3-
echo "publish gtoolkit_bridge PyPI"
3+
echo "running publish gtoolkit_bridge PyPI script"
44

55
# requirements:
66
# - python3 (apt install python)
77
# - curl (apt install curl)
88
# - jq (apt install jq)
99
# - flit (pip install flit)
1010

11-
source_version=`cd PyPI/src && python3 -c 'from gtoolkit_bridge import __version__; print(__version__)'`
11+
# this script must be run inside the PyPI directory
12+
13+
source_version=`cd src && python3 -c 'from gtoolkit_bridge import __version__; print(__version__)'`
1214
published_version=`curl -s https://pypi.org/pypi/gtoolkit_bridge/json | jq -r .info.version`
1315

1416
if [ $source_version = $published_version ]
1517
then
1618
echo "no action" $source_version "=" $published_version
1719
else
18-
echo "publish" $published_version ">" $source_version
20+
echo "publishing" $published_version ">" $source_version
1921
# FLIT_PASSWORD must already be set to token pypi-...
20-
# FLIT_USERNAME=__token__ python3 -m flit publish
22+
FLIT_USERNAME=__token__ python3 -m flit publish
23+
echo "publish done"
2124
fi

0 commit comments

Comments
 (0)