1
0
forked from shaytan/rdgen

add archlinux, change RustDesk in all language files

This commit is contained in:
Bryan Gerlach
2025-02-10 23:12:29 -06:00
parent 0f1b1d1d55
commit 286320cd81
4 changed files with 36 additions and 44 deletions

View File

@@ -330,7 +330,7 @@ jobs:
sed -i -e 's|"Copyright © 2025 Purslane Ltd. All rights reserved."|"Copyright © 2025"|' ./flutter/windows/runner/Runner.rc sed -i -e 's|"Copyright © 2025 Purslane Ltd. All rights reserved."|"Copyright © 2025"|' ./flutter/windows/runner/Runner.rc
sed -i -e 's|"rustdesk.exe"|"${{ inputs.filename }}"|' ./flutter/windows/runner/Runner.rc sed -i -e 's|"rustdesk.exe"|"${{ inputs.filename }}"|' ./flutter/windows/runner/Runner.rc
sed -i -e 's|"RustDesk"|"${{ inputs.appname }}"|' ./flutter/windows/runner/Runner.rc sed -i -e 's|"RustDesk"|"${{ inputs.appname }}"|' ./flutter/windows/runner/Runner.rc
sed -i -e 's|RustDesk|${{ inputs.appname }}|' ./src/lang/en.rs find ./src/lang -name "*.rs" -exec sed -i -e 's|RustDesk|${{ inputs.appname }}|' {} \;
sed -i -e 's|RustDesk|${{ inputs.appname }}|' ./flutter/android/app/src/main/res/values/strings.xml sed -i -e 's|RustDesk|${{ inputs.appname }}|' ./flutter/android/app/src/main/res/values/strings.xml
sed -i -e "s|title: 'RustDesk'|title: '${{ inputs.appname }}'|" ./flutter/lib/main.dart sed -i -e "s|title: 'RustDesk'|title: '${{ inputs.appname }}'|" ./flutter/lib/main.dart
sed -i -e "s|return 'RustDesk';|return '${{ inputs.appname }}';|" ./flutter/lib/web/bridge.dart sed -i -e "s|return 'RustDesk';|return '${{ inputs.appname }}';|" ./flutter/lib/web/bridge.dart

View File

@@ -275,7 +275,7 @@ jobs:
sed -i -e 's|ProductName = "RustDesk"|ProductName = "${{ inputs.appname }}"|' ./libs/portable/Cargo.toml sed -i -e 's|ProductName = "RustDesk"|ProductName = "${{ inputs.appname }}"|' ./libs/portable/Cargo.toml
sed -i -e 's|FileDescription = "RustDesk Remote Desktop"|FileDescription = "${{ inputs.appname }}"|' ./libs/portable/Cargo.toml sed -i -e 's|FileDescription = "RustDesk Remote Desktop"|FileDescription = "${{ inputs.appname }}"|' ./libs/portable/Cargo.toml
sed -i -e 's|OriginalFilename = "rustdesk.exe"|OriginalFilename = "${{ inputs.appname }}.exe"|' ./libs/portable/Cargo.toml sed -i -e 's|OriginalFilename = "rustdesk.exe"|OriginalFilename = "${{ inputs.appname }}.exe"|' ./libs/portable/Cargo.toml
sed -i -e 's|RustDesk|${{ inputs.appname }}|' ./src/lang/en.rs find ./src/lang -name "*.rs" -exec sed -i -e 's|RustDesk|${{ inputs.appname }}|' {} \;
sed -i -e '/-p tmpdeb\/usr\/lib\/rustdesk/d' ./build.py sed -i -e '/-p tmpdeb\/usr\/lib\/rustdesk/d' ./build.py
- name: allow custom.txt - name: allow custom.txt
@@ -361,22 +361,6 @@ jobs:
name: bridge-artifact name: bridge-artifact
path: ./ path: ./
# - name: logo stuff
# if: ${{ inputs.logolink != 'false' }}
# continue-on-error: true
# shell: bash
# run: |
# #echo "${{ inputs.logobase64 }}" | base64 -d > ./rustdesk/data/flutter_assets/assets/logo.png
# wget -O ./rustdesk/data/flutter_assets/assets/logo.png https://${{ fromJson(inputs.logolink).url }}/get_png?filename=${{ fromJson(inputs.logolink).file }}"&"uuid=${{ fromJson(inputs.logolink).uuid }}
# - name: icon stuff
# if: ${{ inputs.iconlink != 'false' }}
# continue-on-error: true
# run: |
# #mv ./rustdesk/data/flutter_assets/assets/icon.svg ./rustdesk/data/flutter_assets/assets/icon.svg.bak
# convert ./res/icon.png ./rustdesk/data/flutter_assets/assets/icon.svg
# convert ./res/icon.png ./rustdesk/data/flutter_assets/assets/scalable.svg
- name: Report Status - name: Report Status
uses: fjogeleit/http-request-action@v1 uses: fjogeleit/http-request-action@v1
with: with:
@@ -575,25 +559,37 @@ jobs:
mv "$name" /workspace/output/"${{ inputs.filename }}-suse.rpm" mv "$name" /workspace/output/"${{ inputs.filename }}-suse.rpm"
done done
# - name: Publish debian/rpm package # only x86_64 for arch since we can not find newest arm64 docker image to build
# if: env.UPLOAD_ARTIFACT == 'true' # old arch image does not make sense for arch since it is "arch" which always update to date
# uses: softprops/action-gh-release@v1 # and failed to makepkg arm64 on x86_64
# with: - name: Patch archlinux PKGBUILD
# prerelease: true if: matrix.job.arch == 'x86_64' && env.UPLOAD_ARTIFACT == 'true'
# tag_name: ${{ env.TAG_NAME }} run: |
# files: | sed -i "s/x86_64/${{ matrix.job.arch }}/g" res/PKGBUILD
# rustdesk-*.deb if [[ "${{ matrix.job.arch }}" == "aarch64" ]]; then
# rustdesk-*.rpm sed -i "s/x86_64/aarch64/g" ./res/PKGBUILD
fi
# - name: Upload to FTP - name: Build archlinux package
# if: ${{ fromJson(inputs.extras).rdgen == 'true' }} if: matrix.job.arch == 'x86_64' && env.UPLOAD_ARTIFACT == 'true'
# uses: SamKirkland/FTP-Deploy-Action@v4.3.5 uses: rustdesk-org/arch-makepkg-action@master
# with: with:
# server: ${{ secrets.GEN_FTP_SERVER }} packages:
# username: ${{ secrets.GEN_FTP_USER }} scripts: |
# password: ${{ secrets.GEN_FTP_PASSWORD }} cd res && HBB=`pwd`/.. FLUTTER=1 makepkg -f
# local-dir: output/
# server-dir: /root/rdgen/exe/${{ env.UUIDFOLDER }}/ - name: Publish archlinux package
if: matrix.job.arch == 'x86_64' && env.UPLOAD_ARTIFACT == 'true'
uses: softprops/action-gh-release@v1
with:
prerelease: true
tag_name: ${{ env.TAG_NAME }}
files: |
res/rustdesk-${{ env.VERSION }}*.zst
- name: Rename archlinux package
run: |
mv ./res/rustdesk-${{ env.VERSION }}-x86_64.pkg.tar.zst ./output/${{ inputs.filename }}.pkg.tar.zst
- name: send file to rdgen server - name: send file to rdgen server
if: ${{ fromJson(inputs.extras).rdgen == 'true' }} if: ${{ fromJson(inputs.extras).rdgen == 'true' }}
@@ -602,6 +598,7 @@ jobs:
curl -i -X POST -H "Content-Type: multipart/form-data" -H "Authorization: Bearer ${{ fromJson(inputs.extras).token }}" -F "file=@./output/${{ inputs.filename }}.deb" -F "uuid=${{ inputs.uuid }}" ${{ secrets.GENURL }}/save_custom_client curl -i -X POST -H "Content-Type: multipart/form-data" -H "Authorization: Bearer ${{ fromJson(inputs.extras).token }}" -F "file=@./output/${{ inputs.filename }}.deb" -F "uuid=${{ inputs.uuid }}" ${{ secrets.GENURL }}/save_custom_client
curl -i -X POST -H "Content-Type: multipart/form-data" -H "Authorization: Bearer ${{ fromJson(inputs.extras).token }}" -F "file=@./output/${{ inputs.filename }}.rpm" -F "uuid=${{ inputs.uuid }}" ${{ secrets.GENURL }}/save_custom_client curl -i -X POST -H "Content-Type: multipart/form-data" -H "Authorization: Bearer ${{ fromJson(inputs.extras).token }}" -F "file=@./output/${{ inputs.filename }}.rpm" -F "uuid=${{ inputs.uuid }}" ${{ secrets.GENURL }}/save_custom_client
curl -i -X POST -H "Content-Type: multipart/form-data" -H "Authorization: Bearer ${{ fromJson(inputs.extras).token }}" -F "file=@./output/${{ inputs.filename }}-suse.rpm" -F "uuid=${{ inputs.uuid }}" ${{ secrets.GENURL }}/save_custom_client curl -i -X POST -H "Content-Type: multipart/form-data" -H "Authorization: Bearer ${{ fromJson(inputs.extras).token }}" -F "file=@./output/${{ inputs.filename }}-suse.rpm" -F "uuid=${{ inputs.uuid }}" ${{ secrets.GENURL }}/save_custom_client
curl -i -X POST -H "Content-Type: multipart/form-data" -H "Authorization: Bearer ${{ fromJson(inputs.extras).token }}" -F "file=@./output/${{ inputs.filename }}.pkg.tar.zst" -F "uuid=${{ inputs.uuid }}" ${{ secrets.GENURL }}/save_custom_client
- name: send file to api server - name: send file to api server
if: ${{ fromJson(inputs.extras).rdgen == 'false' }} if: ${{ fromJson(inputs.extras).rdgen == 'false' }}
@@ -610,13 +607,7 @@ jobs:
curl -i -X POST -H "Content-Type: multipart/form-data" -H "Authorization: Bearer ${{ fromJson(inputs.extras).token }}" -F "file=@./output/${{ inputs.filename }}.deb" ${{ inputs.apiServer }}/api/save_custom_client curl -i -X POST -H "Content-Type: multipart/form-data" -H "Authorization: Bearer ${{ fromJson(inputs.extras).token }}" -F "file=@./output/${{ inputs.filename }}.deb" ${{ inputs.apiServer }}/api/save_custom_client
curl -i -X POST -H "Content-Type: multipart/form-data" -H "Authorization: Bearer ${{ fromJson(inputs.extras).token }}" -F "file=@./output/${{ inputs.filename }}.rpm" ${{ inputs.apiServer }}/api/save_custom_client curl -i -X POST -H "Content-Type: multipart/form-data" -H "Authorization: Bearer ${{ fromJson(inputs.extras).token }}" -F "file=@./output/${{ inputs.filename }}.rpm" ${{ inputs.apiServer }}/api/save_custom_client
curl -i -X POST -H "Content-Type: multipart/form-data" -H "Authorization: Bearer ${{ fromJson(inputs.extras).token }}" -F "file=@./output/${{ inputs.filename }}-suse.rpm" ${{ inputs.apiServer }}/api/save_custom_client curl -i -X POST -H "Content-Type: multipart/form-data" -H "Authorization: Bearer ${{ fromJson(inputs.extras).token }}" -F "file=@./output/${{ inputs.filename }}-suse.rpm" ${{ inputs.apiServer }}/api/save_custom_client
curl -i -X POST -H "Content-Type: multipart/form-data" -H "Authorization: Bearer ${{ fromJson(inputs.extras).token }}" -F "file=@./output/${{ inputs.filename }}.pkg.tar.zst" ${{ inputs.apiServer }}/api/save_custom_client
- name: Upload deb
uses: actions/upload-artifact@master
if: env.UPLOAD_ARTIFACT == 'true'
with:
name: rustdesk-${{ env.VERSION }}-${{ matrix.job.arch }}.deb
path: rustdesk-${{ env.VERSION }}-${{ matrix.job.arch }}.deb
- name: Report Status - name: Report Status
uses: fjogeleit/http-request-action@v1 uses: fjogeleit/http-request-action@v1

View File

@@ -199,7 +199,7 @@ jobs:
cp ./src/lang/en.rs ./src/lang/en.rs.bak cp ./src/lang/en.rs ./src/lang/en.rs.bak
cp ./src/lang/nl.rs ./src/lang/nl.rs.bak cp ./src/lang/nl.rs ./src/lang/nl.rs.bak
sed -i '' -e 's|RustDesk|${{ inputs.appname }}|' ./src/lang/en.rs find ./src/lang -name "*.rs" -exec sed -i '' -e 's|RustDesk|${{ inputs.appname }}|' {} \;
sed -i '' -e 's|RustDesk|${{ inputs.appname }}|' ./src/lang/nl.rs sed -i '' -e 's|RustDesk|${{ inputs.appname }}|' ./src/lang/nl.rs
sed -i '' -e 's|Homepage: https://rustdesk.com|Homepage: ${{ fromJson(inputs.extras).urlLink }}|' ./build.py sed -i '' -e 's|Homepage: https://rustdesk.com|Homepage: ${{ fromJson(inputs.extras).urlLink }}|' ./build.py

View File

@@ -133,6 +133,7 @@
<a href='/download?filename={{filename}}.deb&uuid={{uuid}}' class="download-link">Download {{filename}}.deb</a> <a href='/download?filename={{filename}}.deb&uuid={{uuid}}' class="download-link">Download {{filename}}.deb</a>
<a href='/download?filename={{filename}}.rpm&uuid={{uuid}}' class="download-link">Download {{filename}}.rpm</a> <a href='/download?filename={{filename}}.rpm&uuid={{uuid}}' class="download-link">Download {{filename}}.rpm</a>
<a href='/download?filename={{filename}}-suse.rpm&uuid={{uuid}}' class="download-link">Download {{filename}}-suse.rpm</a> <a href='/download?filename={{filename}}-suse.rpm&uuid={{uuid}}' class="download-link">Download {{filename}}-suse.rpm</a>
<a href='/download?filename={{filename}}.pkg.tar.zst&uuid={{uuid}}' class="download-link">Download {{filename}}.pkg.tar.zst</a>
{% elif platform == 'android' %} {% elif platform == 'android' %}
<a href='/download?filename={{filename}}-aarch64.apk&uuid={{uuid}}' class="download-link">Download {{filename}}-aarch64.apk</a> <a href='/download?filename={{filename}}-aarch64.apk&uuid={{uuid}}' class="download-link">Download {{filename}}-aarch64.apk</a>
<a href='/download?filename={{filename}}-x86_64.apk&uuid={{uuid}}' class="download-link">Download {{filename}}-x86_64.apk</a> <a href='/download?filename={{filename}}-x86_64.apk&uuid={{uuid}}' class="download-link">Download {{filename}}-x86_64.apk</a>