[ci] push sources on every master push (#3007)

Signed-off-by: crueter <crueter@eden-emu.dev>
Reviewed-on: https://git.eden-emu.dev/eden-emu/eden/pulls/3007
This commit is contained in:
crueter
2025-11-12 04:38:32 +01:00
parent f32f356c40
commit b7584cb2c3
3 changed files with 22 additions and 20 deletions

19
.github/workflows/sources.yml vendored Normal file
View File

@@ -0,0 +1,19 @@
name: tx-src
on:
push:
branches: [ master ]
jobs:
license-header:
runs-on: source
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Push New Sources
run: |
export PATH=/usr/lib/qt6/bin:$PATH
./tools/translations/qt-source.sh
tx-cli push -s

View File

@@ -1,14 +0,0 @@
#!/bin/sh
# SPDX-FileCopyrightText: Copyright 2025 Eden Emulator Project
# SPDX-License-Identifier: GPL-3.0-or-later
for i in dist/languages/*.ts; do
SRC=en_US
TARGET=`head -n1 $i | awk -F 'language="' '{split($2, a, "\""); print a[1]}'`
# requires fd
SOURCES=`fd . src/yuzu src/qt_common -tf -e ui -e cpp -e h -e plist`
lupdate -source-language $SRC -target-language $TARGET $SOURCES -ts /data/code/eden/$i
done

View File

@@ -3,10 +3,7 @@
# SPDX-FileCopyrightText: Copyright 2025 Eden Emulator Project
# SPDX-License-Identifier: GPL-3.0-or-later
SRC=en_US
TARGET=en_US
SOURCES=$(find src/yuzu src/qt_common -type f \( -name "*.ui" -o -name "*.cpp" -o -name "*.h" -o -name "*.plist" \))
# requires fd
SOURCES=`fd . src/yuzu src/qt_common -tf -e ui -e cpp -e h -e plist`
lupdate -source-language $SRC -target-language $TARGET $SOURCES -ts dist/languages/en.ts
# shellcheck disable=SC2086
lupdate -source-language en_US -target-language en_US $SOURCES -ts dist/languages/en.ts