From 1ba0aa0db6fe3df6699db7b28e2d3d59c92716aa Mon Sep 17 00:00:00 2001 From: remi durand Date: Fri, 4 Jun 2021 13:57:01 +0200 Subject: [PATCH] update release script to avoid collision with nightly --- .github/workflows/ccpp_mac_rc.yml | 4 ++-- .github/workflows/ccpp_ubuntu_rc.yml | 4 ++-- .github/workflows/ccpp_win_rc.yml | 2 +- create_release.py | 8 ++++---- 4 files changed, 9 insertions(+), 9 deletions(-) diff --git a/.github/workflows/ccpp_mac_rc.yml b/.github/workflows/ccpp_mac_rc.yml index 05b4b565b..01c812618 100644 --- a/.github/workflows/ccpp_mac_rc.yml +++ b/.github/workflows/ccpp_mac_rc.yml @@ -92,10 +92,10 @@ jobs: - name: Upload artifact uses: actions/upload-artifact@v1.0.0 with: - name: nightly_macos.tar + name: rc_macos.tar path: build/Slic3r.tar - name: Upload artifact uses: actions/upload-artifact@v1.0.0 with: - name: nightly_macos.dmg + name: rc_macos.dmg path: build/Slic3r.dmg diff --git a/.github/workflows/ccpp_ubuntu_rc.yml b/.github/workflows/ccpp_ubuntu_rc.yml index 651955107..d552b0b77 100644 --- a/.github/workflows/ccpp_ubuntu_rc.yml +++ b/.github/workflows/ccpp_ubuntu_rc.yml @@ -73,7 +73,7 @@ jobs: - name: Upload artifact uses: actions/upload-artifact@v1.0.0 with: - name: nightly_linux.tar + name: rc_linux.tar path: build/Slic3r.tar - name: build appimage working-directory: ./build/package @@ -86,6 +86,6 @@ jobs: - name: Upload appimage uses: actions/upload-artifact@v1.0.0 with: - name: Slic3r-AppImage.tar + name: rc-Slic3r-AppImage.tar path: build/package/Slic3r_ubu64.AppImage.tar diff --git a/.github/workflows/ccpp_win_rc.yml b/.github/workflows/ccpp_win_rc.yml index fdbe7d779..eb054a725 100644 --- a/.github/workflows/ccpp_win_rc.yml +++ b/.github/workflows/ccpp_win_rc.yml @@ -108,5 +108,5 @@ jobs: - name: Upload artifact uses: actions/upload-artifact@v1.0.0 with: - name: nightly_win64 + name: rc_win64 path: build/package/ diff --git a/create_release.py b/create_release.py index 36239176b..2f3ee1985 100644 --- a/create_release.py +++ b/create_release.py @@ -46,7 +46,7 @@ with urlopen("https://api.github.com/repos/"+repo+"/actions/artifacts") as f: found_macos = False; print("there is "+ str(artifacts["total_count"])+ " artifacts in the repo"); for entry in artifacts["artifacts"]: - if entry["name"] == "nightly_win64" and not found_win: + if entry["name"] == "rc_win64" and not found_win: found_win = True; print("ask for: "+entry["archive_download_url"]); resp = requests.get(entry["archive_download_url"], headers={'Authorization': 'token ' + github_auth_token,}, allow_redirects=True); @@ -58,7 +58,7 @@ with urlopen("https://api.github.com/repos/"+repo+"/actions/artifacts") as f: ret = subprocess.check_output([path_7zip, "a", "-tzip", base_name+".zip", base_name]); except: print("Failed to zip the win directory, do it yourself"); - if entry["name"] == "nightly_macos.dmg" and not found_macos: + if entry["name"] == "rc_macos.dmg" and not found_macos: found_macos = True; print("ask for: "+entry["archive_download_url"]); resp = requests.get(entry["archive_download_url"], headers={'Authorization': 'token ' + github_auth_token,}, allow_redirects=True); @@ -66,7 +66,7 @@ with urlopen("https://api.github.com/repos/"+repo+"/actions/artifacts") as f: z = zipfile.ZipFile(io.BytesIO(resp.content)); z.extractall(release_path); os.rename(release_path+"/"+program_name+".dmg", release_path+"/"+program_name+"_"+version+"_macos_"+date_str+".dmg"); - if entry["name"] == program_name+"-AppImage.tar" and not found_linux_appimage: + if entry["name"] == "rc-"+program_name+"-AppImage.tar" and not found_linux_appimage: found_linux_appimage = True; print("ask for: "+entry["archive_download_url"]); resp = requests.get(entry["archive_download_url"], headers={'Authorization': 'token ' + github_auth_token,}, allow_redirects=True); @@ -77,7 +77,7 @@ with urlopen("https://api.github.com/repos/"+repo+"/actions/artifacts") as f: my_tar.extractall(release_path); my_tar.close(); os.rename(release_path+"/"+program_name+"_ubu64.AppImage", release_path+"/"+program_name+"-ubuntu_18.04-" + version + ".AppImage"); - if entry["name"] == "nightly_linux.tar" and not found_linux: + if entry["name"] == "rc_linux.tar" and not found_linux: found_linux = True; print("ask for: "+entry["archive_download_url"]); resp = requests.get(entry["archive_download_url"], headers={'Authorization': 'token ' + github_auth_token,}, allow_redirects=True);