From 4b9e0e93aa8accf7e93916c1c5af907b6f5d2a33 Mon Sep 17 00:00:00 2001 From: BruceChen Date: Fri, 27 Mar 2026 22:47:20 +0800 Subject: [PATCH 1/5] Fix: cursor locate at the beginning when pressing Up to view history --- MinecraftClient/Tui/MainTuiView.cs | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/MinecraftClient/Tui/MainTuiView.cs b/MinecraftClient/Tui/MainTuiView.cs index 397f1475..7f140d0c 100644 --- a/MinecraftClient/Tui/MainTuiView.cs +++ b/MinecraftClient/Tui/MainTuiView.cs @@ -509,6 +509,17 @@ namespace MinecraftClient.Tui { _commandInput.TextChanged += OnCommandTextChanged; } + + Dispatcher.UIThread.Post(() => + { + var endKeyEvent = new KeyEventArgs + { + RoutedEvent = KeyDownEvent, + Key = Key.End, + Source = _commandInput, + }; + _commandInput.RaiseEvent(endKeyEvent); + }, DispatcherPriority.Input); } #endregion From c42133797edcd76bc208e03600d8f46d298966cf Mon Sep 17 00:00:00 2001 From: BruceChen Date: Sat, 28 Mar 2026 00:30:53 +0800 Subject: [PATCH 2/5] Update build-and-release.yml to enhance translation fetching logic - Modified the condition for fetching translations to include checks for CROWDIN_PROJECT_ID and CROWDIN_PERSONAL_TOKEN. - Added environment variables for CROWDIN credentials to streamline the translation process. --- .github/workflows/build-and-release.yml | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/.github/workflows/build-and-release.yml b/.github/workflows/build-and-release.yml index e0baaa91..8901321d 100644 --- a/.github/workflows/build-and-release.yml +++ b/.github/workflows/build-and-release.yml @@ -34,11 +34,12 @@ jobs: fail-fast: true runs-on: ubuntu-latest needs: determine-build - # Translations will only be fetched in the MCCTeam repository, since it needs crowdin secrets. - if: ${{ needs.determine-build.outputs.skip != 'true' && github.repository == 'MCCTeam/Minecraft-Console-Client' }} + + if: ${{ needs.determine-build.outputs.skip != 'true' }} + timeout-minutes: 15 - - steps: + + steps: - name: Check cache uses: actions/cache/restore@v3 id: cache-check @@ -52,12 +53,13 @@ jobs: if: steps.cache-check.outputs.cache-hit != 'true' uses: actions/checkout@v3 with: - fetch-depth: 0 - submodules: 'true' + fetch-depth: 0 + submodules: 'true' - name: Download translations from crowdin uses: crowdin/github-action@v1.6.0 - if: steps.cache-check.outputs.cache-hit != 'true' + # Translations will only be fetched when Crowdin tokens are available. + if: ${{ steps.cache-check.outputs.cache-hit != 'true' && secrets.CROWDIN_PROJECT_ID && secrets.CROWDIN_TOKEN }} with: upload_sources: false upload_translations: false From da330a158ee55dc79ee06a91c9c41619b8084849 Mon Sep 17 00:00:00 2001 From: BruceChen Date: Sat, 28 Mar 2026 00:36:02 +0800 Subject: [PATCH 3/5] Enhance Crowdin integration in build-and-release.yml - Added a step to check for the availability of Crowdin secrets before downloading translations. - Updated the condition for fetching translations to rely on the new check for Crowdin credentials. - Corrected the assembly configuration to use the correct date format for builds. --- .github/workflows/build-and-release.yml | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build-and-release.yml b/.github/workflows/build-and-release.yml index 8901321d..9cde2ae2 100644 --- a/.github/workflows/build-and-release.yml +++ b/.github/workflows/build-and-release.yml @@ -56,10 +56,21 @@ jobs: fetch-depth: 0 submodules: 'true' + - name: Check Crowdin secrets + id: crowdin-check + run: | + if [ -z "$CROWDIN_PROJECT_ID" ] || [ -z "$CROWDIN_PERSONAL_TOKEN" ]; then + echo "available=false" >> $GITHUB_OUTPUT + else + echo "available=true" >> $GITHUB_OUTPUT + fi + env: + CROWDIN_PROJECT_ID: ${{ secrets.CROWDIN_PROJECT_ID }} + CROWDIN_PERSONAL_TOKEN: ${{ secrets.CROWDIN_TOKEN }} + - name: Download translations from crowdin uses: crowdin/github-action@v1.6.0 - # Translations will only be fetched when Crowdin tokens are available. - if: ${{ steps.cache-check.outputs.cache-hit != 'true' && secrets.CROWDIN_PROJECT_ID && secrets.CROWDIN_TOKEN }} + if: steps.cache-check.outputs.cache-hit != 'true' && steps.crowdin-check.outputs.available == 'true' with: upload_sources: false upload_translations: false @@ -172,7 +183,7 @@ jobs: - name: Set Version Info run: | echo '' >> ${{ env.assembly-info }} - echo "[assembly: AssemblyConfiguration(\"GitHub build ${{ github.run_number }}, built on ${{ env._dashed }} from commit ${{ env.commit }}\")]" >> ${{ env.assembly-info }} + echo "[assembly: AssemblyConfiguration(\"GitHub build ${{ github.run_number }}, built on ${{ env.date_dashed }} from commit ${{ env.commit }}\")]" >> ${{ env.assembly-info }} - name: Inject Sentry DSN (if applicable) if: ${{ github.repository == 'MCCTeam/Minecraft-Console-Client' }} From ef8e41196b2e8e13a983a777bf0343afebdb99c5 Mon Sep 17 00:00:00 2001 From: BruceChen Date: Sat, 28 Mar 2026 00:40:05 +0800 Subject: [PATCH 4/5] Update Crowdin GitHub Action version in build-and-release.yml - Upgraded the Crowdin GitHub Action from v1.6.0 to v1.20.4 to leverage the latest features and improvements. --- .github/workflows/build-and-release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-and-release.yml b/.github/workflows/build-and-release.yml index 9cde2ae2..97147eb8 100644 --- a/.github/workflows/build-and-release.yml +++ b/.github/workflows/build-and-release.yml @@ -69,7 +69,7 @@ jobs: CROWDIN_PERSONAL_TOKEN: ${{ secrets.CROWDIN_TOKEN }} - name: Download translations from crowdin - uses: crowdin/github-action@v1.6.0 + uses: crowdin/github-action@v1.20.4 if: steps.cache-check.outputs.cache-hit != 'true' && steps.crowdin-check.outputs.available == 'true' with: upload_sources: false From 19a60fd85c0305268ae1ca5a8e40d0589820f182 Mon Sep 17 00:00:00 2001 From: BruceChen Date: Sat, 28 Mar 2026 00:43:28 +0800 Subject: [PATCH 5/5] Update Crowdin GitHub Action version in build-and-release.yml - Upgraded the Crowdin GitHub Action from v1.20.4 to v2.4.0 to incorporate the latest updates and improvements. --- .github/workflows/build-and-release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-and-release.yml b/.github/workflows/build-and-release.yml index 97147eb8..359bd388 100644 --- a/.github/workflows/build-and-release.yml +++ b/.github/workflows/build-and-release.yml @@ -69,7 +69,7 @@ jobs: CROWDIN_PERSONAL_TOKEN: ${{ secrets.CROWDIN_TOKEN }} - name: Download translations from crowdin - uses: crowdin/github-action@v1.20.4 + uses: crowdin/github-action@v2.4.0 if: steps.cache-check.outputs.cache-hit != 'true' && steps.crowdin-check.outputs.available == 'true' with: upload_sources: false