-
Notifications
You must be signed in to change notification settings - Fork 2
/
release.sh
executable file
·59 lines (43 loc) · 1.24 KB
/
release.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
#!/bin/bash
VERSION=1.1.14
function make_release() {
MODULE=$1
echo
echo Releasing $MODULE at $VERSION
echo
mkdir -p release
mkdir release/$MODULE
sed s/VERSIONID/$VERSION/g release_files/setup_$MODULE.py >>release/$MODULE/setup.py
cp release_files/README_$MODULE.md release/$MODULE/README.md
cp release_files/MANIFEST.in release/$MODULE/MANIFEST.in
for i in "${@:2}"
do
echo copying $i
cp -r $i release/$MODULE/$i
done
PASSWORD=$(<pypi_password)
cd release/$MODULE/
conda remove --name yo_release --all -y
conda create --name yo_release python=3.6 -y
source activate yo_release
pip install twine
python setup.py test || exit 1
python setup.py sdist bdist_wheel;
twine upload -u okulovsky -p $PASSWORD dist/* --verbose
sleep 5
pip install $MODULE==$VERSION
sleep 5
pip install $MODULE==$VERSION
if [ $? -eq 0 ];
then
echo ================ PUBLISHED ======================
else
exit
fi
source deactivate
cd ../..
}
./coverage.sh || exit 1
rm -rf release
make_release yo_fluq yo_fluq yo_fluq__tests
make_release yo_fluq_ds yo_fluq_ds yo_fluq__tests yo_fluq_ds__tests