Skip to content

Commit

Permalink
U | sync to legacy
Browse files Browse the repository at this point in the history
  • Loading branch information
FTS427 committed Aug 15, 2024
1 parent 1e5e400 commit dd1805b
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 4 deletions.
7 changes: 3 additions & 4 deletions .github/workflows/auto_pack.yml
Original file line number Diff line number Diff line change
Expand Up @@ -114,8 +114,7 @@ jobs:
id: get_bds_core_version
working-directory: ll
run: |
$file = Get-ChildItem -Path .\.cache\bdsdown\ -File | Select-Object -First 1
"bds_core_version=$(echo $file.Name)" | Out-File -FilePath $env:GITHUB_OUTPUT -Append
"bds_core_version=$(python ..\scripts\get_bds_version.py)" | Out-File -FilePath $env:GITHUB_OUTPUT -Append
rm .\behavior_packs -Force -Recurse
rm .\definitions -Force -Recurse
rm .\resource_packs -Force -Recurse
Expand All @@ -130,12 +129,12 @@ jobs:
- name: 📦 Pack Files
run: |
7z a ll_${{ steps.formated_ver.outputs.ll_version }}-bds_${{ steps.get_bds_core_version.outputs.bds_core_version }} .\ll\
7z a ll_${{ steps.formated_ver.outputs.ll_version }}-bds_${{ steps.get_bds_core_version.outputs.bds_core_version }}.zip .\ll\
- name: 🎉 Upload Release
uses: softprops/action-gh-release@v1
with:
files: ll_${{ steps.formated_ver.outputs.ll_version }}-bds_${{ steps.get_bds_core_version.outputs.bds_core_version }}
files: ll_${{ steps.formated_ver.outputs.ll_version }}-bds_${{ steps.get_bds_core_version.outputs.bds_core_version }}.zip
name: LeviLamina Packed - ${{ steps.formated_ver.outputs.ll_version }} (auto)
tag_name: auto-${{ steps.formated_ver.outputs.ll_version }}
body: |
Expand Down
23 changes: 23 additions & 0 deletions scripts/get_bds_version.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
import json
import re
try:

with open(".\\.lip\\metadata\\github.com%2FLiteLDev%2Fbds.json") as file:
json_data = file.read()
except FileNotFoundError:
print("File not found")
raise SystemExit
except Exception as e:
print(e)
raise SystemExit
data = json.loads(json_data)

post_install_command = data['commands']['post_install'][0]
match = re.search(r'version://windows/([^\\]+)', post_install_command)

if match:
version_number = match.group(1)
print(version_number)
else:
print("???")

0 comments on commit dd1805b

Please sign in to comment.