Skip to content

Commit

Permalink
Update download.py
Browse files Browse the repository at this point in the history
  • Loading branch information
learnforpractice committed Dec 29, 2021
1 parent a4b8ff1 commit 96af834
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 1 deletion.
11 changes: 10 additions & 1 deletion scripts/download.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import os
import sys
import time
import subprocess

version = sys.argv[1]
Expand All @@ -23,5 +24,13 @@
url = f'https://github.com/learnforpractice/mixin-python/releases/download/v{version}/'

for f in files:
if not os.path.exists(f):
count = 60*60/10
while True:
print('Downloading {}'.format(f))
subprocess.call(['wget', url + f])
if os.path.exists(f):
break
time.sleep(10)
count -= 1
if count <= 0:
break
6 changes: 6 additions & 0 deletions tag.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
VERSION=v0.2.3
git push origin :refs/tags/$VERSION
git tag -d $VERSION
git tag $VERSION -F release.txt
git push -f origin $VERSION

0 comments on commit 96af834

Please sign in to comment.