mirror of
https://github.com/blitzkit/blitzkit.git
synced 2026-10-23 19:49:50 +02:00
feat: yeaaah
This commit is contained in:
1 parent
27a958079f
commit
7e076a1e34
3 files changed
+26
-9
No files matched your search
@@ -6,6 +6,11 @@ on:
|
|||||||
|
|
||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
inputs:
|
inputs:
|
||||||
|
cdn_branch:
|
||||||
|
type: string
|
||||||
|
required: false
|
||||||
|
default: main
|
||||||
|
description: What CDN branch to write to
|
||||||
zip_url:
|
zip_url:
|
||||||
type: string
|
type: string
|
||||||
required: false
|
required: false
|
||||||
@@ -14,10 +19,6 @@ on:
|
|||||||
type: string
|
type: string
|
||||||
required: false
|
required: false
|
||||||
description: Root dir of ZIP which houses the executable and Data dir
|
description: Root dir of ZIP which houses the executable and Data dir
|
||||||
zip_branch:
|
|
||||||
type: string
|
|
||||||
required: false
|
|
||||||
description: What CDN branch must the ZIP be written to
|
|
||||||
|
|
||||||
schedule:
|
schedule:
|
||||||
- cron: '0 2 * * *'
|
- cron: '0 2 * * *'
|
||||||
@@ -41,14 +42,17 @@ jobs:
|
|||||||
run: bun install
|
run: bun install
|
||||||
|
|
||||||
- name: Setup DepotDownloader
|
- name: Setup DepotDownloader
|
||||||
|
if: github.event.inputs.zip_url == ''
|
||||||
run: bun scripts/setupDepotDownloader.ts
|
run: bun scripts/setupDepotDownloader.ts
|
||||||
|
|
||||||
- name: Run DepotDownloader
|
- name: Download Steam client
|
||||||
|
if: github.event.inputs.zip_url == ''
|
||||||
run: |
|
run: |
|
||||||
chmod +x ./temp/depotDownloader/DepotDownloader
|
chmod +x ./temp/depotDownloader/DepotDownloader
|
||||||
./temp/depotDownloader/DepotDownloader -os windows -app 444200 -username ${{ secrets.DEPOT_DOWNLOADER_USERNAME }} -password "${{ secrets.DEPOT_DOWNLOADER_PASSWORD }}"
|
./temp/depotDownloader/DepotDownloader -os windows -app 444200 -username ${{ secrets.DEPOT_DOWNLOADER_USERNAME }} -password "${{ secrets.DEPOT_DOWNLOADER_PASSWORD }}"
|
||||||
|
|
||||||
- name: Apply patches
|
- name: Apply patches
|
||||||
|
if: github.event.inputs.zip_url == ''
|
||||||
env:
|
env:
|
||||||
DISCORD_CLIENT_ID: ${{ secrets.DISCORD_CLIENT_ID }}
|
DISCORD_CLIENT_ID: ${{ secrets.DISCORD_CLIENT_ID }}
|
||||||
GH_TOKEN: ${{ secrets.GH_TOKEN }}
|
GH_TOKEN: ${{ secrets.GH_TOKEN }}
|
||||||
@@ -57,6 +61,17 @@ jobs:
|
|||||||
WOTB_DLC_CDN: ${{ secrets.WOTB_DLC_CDN }}
|
WOTB_DLC_CDN: ${{ secrets.WOTB_DLC_CDN }}
|
||||||
run: bun scripts/applyPatches.ts --depot
|
run: bun scripts/applyPatches.ts --depot
|
||||||
|
|
||||||
|
- name: Download ZIP client
|
||||||
|
if: github.event.inputs.zip_url != ''
|
||||||
|
env:
|
||||||
|
ZIP_URL: ${{ github.event.inputs.zip_url }}
|
||||||
|
ZIP_ROOT: ${{ github.event.inputs.zip_root }}
|
||||||
|
run: |
|
||||||
|
curl -o client.zip $ZIP_URL
|
||||||
|
unzip client.zip
|
||||||
|
rm client.zip
|
||||||
|
mv $ZIP_ROOT depots/444202/0
|
||||||
|
|
||||||
- name: Build assets
|
- name: Build assets
|
||||||
env:
|
env:
|
||||||
DISCORD_CLIENT_ID: ${{ secrets.DISCORD_CLIENT_ID }}
|
DISCORD_CLIENT_ID: ${{ secrets.DISCORD_CLIENT_ID }}
|
||||||
@@ -65,4 +80,5 @@ jobs:
|
|||||||
DATABASE_URL: ${{ secrets.DATABASE_URL }}
|
DATABASE_URL: ${{ secrets.DATABASE_URL }}
|
||||||
VIDEOS_SHEET: ${{ secrets.VIDEOS_SHEET }}
|
VIDEOS_SHEET: ${{ secrets.VIDEOS_SHEET }}
|
||||||
GOOGLE_APPLICATION_CREDENTIALS: ${{ secrets.GOOGLE_APPLICATION_CREDENTIALS }}
|
GOOGLE_APPLICATION_CREDENTIALS: ${{ secrets.GOOGLE_APPLICATION_CREDENTIALS }}
|
||||||
|
NEXT_PUBLIC_ASSET_BRANCH: ${{ github.event.inputs.cdn_branch }}
|
||||||
run: bun build:assets --all-targets --depot --production
|
run: bun build:assets --all-targets --depot --production
|
||||||
@@ -3,11 +3,9 @@ import { argv } from 'process';
|
|||||||
|
|
||||||
const isDepot = argv.includes('--depot');
|
const isDepot = argv.includes('--depot');
|
||||||
|
|
||||||
export const WOTB_WIN32_DEPOT = 444202;
|
|
||||||
|
|
||||||
export const DATA = isDepot
|
export const DATA = isDepot
|
||||||
? await (async () => {
|
? await (async () => {
|
||||||
const [installationVersion] = await readdir(`depots/${WOTB_WIN32_DEPOT}`);
|
const [installationVersion] = await readdir(`depots/444202`);
|
||||||
return `depots/${WOTB_WIN32_DEPOT}/${installationVersion}/Data`;
|
return `depots/444202/${installationVersion}/Data`;
|
||||||
})()
|
})()
|
||||||
: 'C:/Program Files (x86)/Steam/steamapps/common/World of Tanks Blitz/Data';
|
: 'C:/Program Files (x86)/Steam/steamapps/common/World of Tanks Blitz/Data';
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
import { assertSecret } from '../src/core/blitzkit/secret';
|
||||||
|
|
||||||
|
assertSecret(process.env.ZIP_URL);
|
||||||
Reference in new issue
Block a user