File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -30,3 +30,7 @@ release: clean
3030
3131install : clean
3232 poetry install
33+
34+ publish :
35+ @bin/publish
36+
Original file line number Diff line number Diff line change 1+ #! /bin/bash
2+
3+ if [ -z " $PYPI_USER " ]; then
4+ echo ' $PYPI_USER is not set.'
5+ exit 1
6+ fi
7+
8+ if [ -z " $PYPI_PASSWORD " ]; then
9+ echo ' $PYPI_PASSWORD is not set.'
10+ exit 1
11+ fi
12+
13+ changes=` git diff`
14+
15+ if [ -n " ${changes} " ]; then
16+ echo " You have made changes to this branch that you have not committed."
17+ exit 1
18+ fi
19+
20+ staged_changes=` git diff --staged`
21+
22+ if [ -n " ${staged_changes} " ]; then
23+ echo " You have staged changes to this branch that you have not committed."
24+ exit 1
25+ fi
26+
27+ tagged=` git log -1 --decorate | head -1 | grep ' tag:' `
28+
29+ if [ -z " $tagged " ]; then
30+ # We don't encourage people to tag it unless they have no changes pending.
31+ echo " You can only publish a tagged commit."
32+ exit 1
33+ fi
34+
35+ read -p " Are you sure you want to publish $( poetry version) to PyPi? "
36+ REPLY=` echo " $REPLY " | tr ' [:upper:]' ' [:lower:]' `
37+ if [ " $REPLY " != ' y' ] && [ " $REPLY " != " yes" ]
38+ then
39+ echo " Publishing aborted."
40+ exit 1
41+ fi
42+
43+ poetry publish --no-interaction --build --username=$PYPI_USER --password=$PYPI_PASSWORD
Original file line number Diff line number Diff line change 11[tool .poetry ]
22name = " python-lambda-4dn"
3- version = " 2.0.0b2 "
3+ version = " 2.0.0b3 "
44description = " A forked version of python-lambda for 4DN-DCIC use in packaging and deploying lambda functions."
55authors = [" 4DN-DCIC Team <support@4dnucleome.org>" ]
66license = " MIT"
You can’t perform that action at this time.
0 commit comments