hugo github workflow error
Sembari membantu U3 FI1201 [1] berupaya untuk meregistrasi permasalan workflow dari bugx ini yang belum terpecahkan. Sebelumnya sempat berfungsi dengan baik.
solution#
The example is for a private repository (user: dudung, repo: bugx-hugo-src), but you can adapt it to yours.
steps#
- Explore the page listing commits of a branch 
https://github.com/dudung/bugx-hugo-src/commits/master - Look for the last failed check indicated with $\color{#f00}{\times}$ 
https://github.com/dudung/bugx-hugo-src/commit/22c32b416cc22cb81f4c61985bd95931feb5658f - Visit build page showing the failed action by clicking $\color{#f00}{\times}$ indicator 
https://github.com/dudung/bugx-hugo-src/runs/6548801081?check_suite_focus=true 
(×) Deploy
... 
590 remote: Invalid username or password.
591 fatal: Authentication failed for 
    'https://github.com/dudung/bugx.git/'
592 Error: Action failed with "The process 
    '/usr/bin/git' failed with exit code 128"
- Go to Actions tab 
https://github.com/dudung/bugx-hugo-src/actions - Select the failed workflow and open the yml file 
https://github.com/dudung/bugx-hugo-src/actions/workflows/main.yml - Find 
Deployandpersonal_token, which givessecrets.PERSONAL_TOKEN - Generate new token and copy the value 
https://github.com/settings/tokens - Open page for action secrets 
https://github.com/dudung/bugx-hugo-src/settings/secrets/actions - Create new repository secret 
https://github.com/dudung/bugx-hugo-src/settings/secrets/actions/new - Name it as 
PERSONAL_TOKEN, paste the value from previously new token, and Add secret 
Perhatikan keterkaitan antara Langkah 6 –> 10 dan 7 –> 10.
Pembahasan pada bagian-bagian di bawah ini adalah sebelum solusi yang dimaksud di atas diperoleh dan bagian-bagian tersebut dipertahankan hanya sebagai catatan bagaimana solusi tersebut dapat diperoleh.
current state#
Keadaan saat ini pada suatu repo adalah seperti diberikan pada Gambar 1 berikut.

Gambar 1. Build error dari workflow bugx-hugo-ci.
Isi dari berkas main.yml yang digunakan adalah sebagai berikut ini
name: bugx-hugo-ci
on:
  push:
    branches: [ master ]
jobs:
  build:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v2
        with:
          submodules: true 
          fetch-depth: 1   
      - name: Setup Hugo
        uses: peaceiris/actions-hugo@v2
        with:
          hugo-version: 'latest'
      - name: Build
        run: hugo
      - name: Deploy
        uses: peaceiris/actions-gh-pages@v3
        with:
          personal_token: ${{ secrets.PERSONAL_TOKEN }}
          external_repository: dudung/bugx
          publish_branch: master
          publish_dir: ./public
dengan hanya sedikit penyesuaian dari peaceiris/actions-gh-pages@v3 [2].
tokens#
Suatu token dapat dibuat dengan mengunjungi https://github.com/settings/tokens dan membuatnya dengan nilai seperti
ghp_0Xx0Xx0Xx0Xx0Xx0Xx0Xx0Xx0Xx0Xx0Xx0Xx
yang merupakan kombinasi dari sembarang angka 0, huruf besar X dan huruf kecil x membentuk 36 karakter. Di awalnya terdapat empat karakter ghp_.
secrets#
Kunjungi https://github.com/dudung/bugx/settings/secrets/actions untuk membuat secret

Gambar 2. Daftar action secrets yang tersedia.
yang dalam hal ini adalah PERSONAL_TOKEN

Gambar 3. Memperbaharui PERSONAL_TOKEN dengan nilai token yang telah dibuat.
dengan isi token sebelumnya.
result#
GitHub Workflow akhirnya dapat berjalan kembali seperti pada gambar berikut ini.

Gambar 4. Workflow bugx-hugo-ci di GitHub yang telah berfungsi kembali.
Contoh hasilnya adalah bugx ini yang dapat dilihat pada https://dudung.github.io/bugx/ dengan salah satunya adalah tulisan ini.
notes#
- Tim Ujian, “Panduan Ujian 3 FI1201 (Fisika Dasar IIA)”, FMIPA, ITB, 20 Mei 2022, url https://osf.io/jbtd3/ [20220523].
 - Shohei Ueda (Sponsor) and Other Contributors, “GitHub Pages Action”, GitHub, 17 May 2022, url https://github.com/peaceiris/actions-gh-pages [20220523].