mirror of
https://github.com/Grasscutters/mitmproxy.git
synced 2024-11-29 11:03:13 +00:00
release: put branches in /branches on the snapshots server
This is a precautionary measure to prevent a clash in case we have a branch with the same name as a tag. Tags live in the top-level directory, because these are releases that users will most often access directly.
This commit is contained in:
parent
5cea2aacb2
commit
3a3299bc61
@ -74,8 +74,10 @@ TAG = os.environ.get("TRAVIS_TAG", os.environ.get("APPVEYOR_REPO_TAG_NAME", None
|
||||
BRANCH = os.environ.get("TRAVIS_BRANCH", os.environ.get("APPVEYOR_REPO_BRANCH", None))
|
||||
if TAG:
|
||||
VERSION = TAG
|
||||
UPLOAD_DIR = VERSION
|
||||
elif BRANCH:
|
||||
VERSION = BRANCH
|
||||
UPLOAD_DIR = "branches/%s" % VERSION
|
||||
else:
|
||||
print("Could not establish build name - exiting." % BRANCH)
|
||||
sys.exit(0)
|
||||
@ -240,7 +242,7 @@ def upload():
|
||||
"aws", "s3", "cp",
|
||||
"--acl", "public-read",
|
||||
DIST_DIR + "/",
|
||||
"s3://snapshots.mitmproxy.org/%s/" % VERSION,
|
||||
"s3://snapshots.mitmproxy.org/%s/" % UPLOAD_DIR,
|
||||
"--recursive",
|
||||
]
|
||||
)
|
||||
|
Loading…
Reference in New Issue
Block a user