From 1716747c094f0738ba1ac8f89c3fe36dff43406e Mon Sep 17 00:00:00 2001 From: datadunia Date: Thu, 7 May 2026 12:48:27 +0700 Subject: [PATCH] fix: shallow --- .gitea/workflows/release.yaml | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) diff --git a/.gitea/workflows/release.yaml b/.gitea/workflows/release.yaml index 0afd7ff..13e5964 100644 --- a/.gitea/workflows/release.yaml +++ b/.gitea/workflows/release.yaml @@ -18,15 +18,21 @@ jobs: steps: - name: Clone repository with submodules run: | - # 1. Set config secara global agar terbaca oleh submodule - # Gunakan "token" atau "Bearer" sesuai konfigurasi Gitea Anda - git config --global http.extraheader "Authorization: Bearer ${{ secrets.MY_GITEA_TOKEN }}" + git clone --recurse-submodules -c "url.https://token:${{ gitea.token }}@git.datadunia.com/.insteadOf=https://git.datadunia.com/" https://git.datadunia.com/devops/wireguard-vpn.git - # 2. Matikan prompt agar tidak hang jika otentikasi gagal + git config --global http."https://git.datadunia.com/".extraheader "Authorization: token ${{ gitea.token }}" + + # 2. Matikan prompt interaktif agar tidak berhenti meminta password git config --global core.askPass "" - # 3. Jalankan clone - git clone --recurse-submodules ${{ gitea.server_url }}/${{ gitea.repository }}.git . + # 3. Jalankan clone secara rekursif + # Sekarang proses submodule pasti akan membaca file ~/.gitconfig dan menemukan header tadi + git clone --recurse-submodules https://git.datadunia.com/devops/wireguard-vpn.git . + + # 4. PENTING: Hapus konfigurasi segera setelah selesai (Cleanup) + # Gunakan perintah ini di langkah 'if: always()' jika di Gitea Actions + git config --global --unset-all http."https://git.datadunia.com/".extraheader + git config --global --unset core.askPass # Debug ls -la app/frontend