Skip to content

Commit

Permalink
Update Build and Release.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
yodaluca23 authored Jun 23, 2024
1 parent dcc3394 commit 41b325c
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions .github/workflows/Build and Release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,7 @@ jobs:

#Set Env Varibles
echo "orion=Build Components/$downloaded_file" >> $GITHUB_ENV
echo "ORIONVERSION=$orion_version" >> $GITHUB_ENV
echo "ORIONVERSION=$ORIONVERSION" >> $GITHUB_ENV

- name: Upload Orion to VirusTotal
if: ${{ env.VIRUSTOTALKEY }}
Expand Down Expand Up @@ -271,7 +271,7 @@ jobs:

#Set Env Varibles
echo "sposify=Build Components/$downloaded_file" >> $GITHUB_ENV
echo "SPOSIFYVERSION=$sposify_version" >> $GITHUB_ENV
echo "SPOSIFYVERSION=$SPOSIFYVERSION" >> $GITHUB_ENV


- name: Upload Sposify to VirusTotal
Expand All @@ -294,13 +294,13 @@ jobs:
# Use awk to find entries for dev.theos.orion14, Architecture: iphoneos-arm, find the highest version
# extract the version, filename, SHA256 Hash, and MD5 hash
SPOSIFYFIXVERSION=$(awk 'BEGIN { RS = ""; FS = "\n"; highest_version = "" } $1 ~ /^Package: com.level3tjg.sposifyfix$/ && $0 ~ /Architecture: iphoneos-arm([^6]|$)/ { for (i = 1; i <= NF; i++) { if ($i ~ /^Version: /) { split($i, a, " "); version = a[2]; if (highest_version == "" || version > highest_version) { highest_version = version } } } } END { if (highest_version != "") print highest_version }' Packages)
echo "Sposify Version Extracted: $SPOSIFYFIXVERSION"
echo "SposifyFix Version Extracted: $SPOSIFYFIXVERSION"
FILENAME=$(awk 'BEGIN{RS="";FS="\n";highest_version=""} $1~/^Package: com.level3tjg.sposifyfix$/ && $0~/Architecture: iphoneos-arm/{current_version="";current_filename="";for(i=1;i<=NF;i++){if($i~/^Version: /){split($i,a," ");version=a[2];if(current_version==""||version>current_version){current_version=version}}else if($i~/^Filename: /){split($i,a," ");current_filename=a[2]}}if(highest_version==""||current_version>highest_version){highest_version=current_version;highest_filename=current_filename}} END{if(highest_version!="")print highest_filename}' Packages)
echo "Sposify FileName Extracted: $FILENAME"
echo "SposifyFix FileName Extracted: $FILENAME"
SHA256=$(awk 'BEGIN{RS="";FS="\n";highest_version="";sha256="noSHA"} $1~/^Package: com.level3tjg.sposifyfix$/ && $0~/Architecture: iphoneos-arm/{current_version="";sha256_found=0;for(i=1;i<=NF;i++){if($i~/^Version: /){split($i,a," ");version=a[2];if(current_version==""||version>current_version){current_version=version}}else if($i~/^SHA256: /){split($i,a," ");sha256=a[2];sha256_found=1}}if(highest_version==""||current_version>highest_version){highest_version=current_version;if(sha256_found==1){highest_sha256=sha256}else{highest_sha256="noSHA"}}}END{if(highest_version!="")print highest_sha256}' Packages)
echo "Sposify SHA256 Hash Extracted: $SHA256"
echo "SposifyFix SHA256 Hash Extracted: $SHA256"
MD5=$(awk 'BEGIN{RS="";FS="\n";highest_version="";md5sum="noMD5"} $1~/^Package: ccom.level3tjg.sposifyfix$/ && $0~/Architecture: iphoneos-arm/{current_version="";for(i=1;i<=NF;i++){if($i~/^Version: /){split($i,a," ");version=a[2];if(current_version==""||version>current_version){current_version=version}}else if($i~/^MD5Sum: /){split($i,a," ");md5sum=a[2]}}if(highest_version==""||current_version>highest_version){highest_version=current_version;highest_md5sum=md5sum}} END{if(highest_version!="")print highest_md5sum}' Packages)
echo "Sposify MD5 Hash Extracted: $MD5"
echo "SposifyFix MD5 Hash Extracted: $MD5"

echo "Downloading From: https://level3tjg.me/repo/Packages/$FILENAME"
# Download the file using curl
Expand Down Expand Up @@ -341,7 +341,7 @@ jobs:

#Set Env Varibles
echo "sposifyfix=Build Components/$downloaded_file" >> $GITHUB_ENV
echo "SPOSIFYFIXVERSION=$sposify_version" >> $GITHUB_ENV
echo "SPOSIFYFIXVERSION=$SPOSIFYFIXVERSION" >> $GITHUB_ENV

- name: Upload SposifyFix to VirusTotal
if: ${{ env.VIRUSTOTALKEY }}
Expand All @@ -366,7 +366,7 @@ jobs:
- name: Compress OpenSpotifySafariExtension to zip
run: |
cd OpenSpotifySafariExtension
zip -r "Build Components/OpenSpotifySafariExtension.zip" ./*
zip -r "Build Components/OpenSpotifySafariExtension.zip"
- name: Upload OpenSpotifySafariExtension to VirusTotal
if: ${{ env.VIRUSTOTALKEY }}
Expand Down

0 comments on commit 41b325c

Please sign in to comment.